Home Assistant Unofficial Reference 2024.12.1
homeassistant.components.local_todo.todo Namespace Reference

Classes

class  LocalTodoListEntity
 

Functions

Todo _convert_item (TodoItem item)
 
bool _migrate_calendar (Calendar calendar)
 
None async_setup_entry (HomeAssistant hass, LocalTodoConfigEntry config_entry, AddEntitiesCallback async_add_entities)
 

Variables

 _LOGGER = logging.getLogger(__name__)
 
dictionary ICS_TODO_STATUS_MAP
 
dictionary ICS_TODO_STATUS_MAP_INV
 
string PRODID = "-//homeassistant.io//local_todo 2.0//EN"
 
string PRODID_REQUIRES_MIGRATION = "-//homeassistant.io//local_todo 1.0//EN"
 

Detailed Description

A Local To-do todo platform.

Function Documentation

◆ _convert_item()

Todo homeassistant.components.local_todo.todo._convert_item ( TodoItem  item)
private
Convert a HomeAssistant TodoItem to an ical Todo.

Definition at line 93 of file todo.py.

◆ _migrate_calendar()

bool homeassistant.components.local_todo.todo._migrate_calendar ( Calendar  calendar)
private
Upgrade due dates to rfc5545 format.

In rfc5545 due dates are exclusive, however we previously set the due date
as inclusive based on what the user set in the UI. A task is considered
overdue at midnight at the start of a date so we need to shift the due date
to the next day for old calendar versions.

Definition at line 46 of file todo.py.

◆ async_setup_entry()

None homeassistant.components.local_todo.todo.async_setup_entry ( HomeAssistant  hass,
LocalTodoConfigEntry  config_entry,
AddEntitiesCallback  async_add_entities 
)
Set up the local_todo todo platform.

Definition at line 65 of file todo.py.

Variable Documentation

◆ _LOGGER

homeassistant.components.local_todo.todo._LOGGER = logging.getLogger(__name__)
private

Definition at line 28 of file todo.py.

◆ ICS_TODO_STATUS_MAP

dictionary homeassistant.components.local_todo.todo.ICS_TODO_STATUS_MAP
Initial value:
1 = {
2  TodoStatus.IN_PROCESS: TodoItemStatus.NEEDS_ACTION,
3  TodoStatus.NEEDS_ACTION: TodoItemStatus.NEEDS_ACTION,
4  TodoStatus.COMPLETED: TodoItemStatus.COMPLETED,
5  TodoStatus.CANCELLED: TodoItemStatus.COMPLETED,
6 }

Definition at line 34 of file todo.py.

◆ ICS_TODO_STATUS_MAP_INV

dictionary homeassistant.components.local_todo.todo.ICS_TODO_STATUS_MAP_INV
Initial value:
1 = {
2  TodoItemStatus.COMPLETED: TodoStatus.COMPLETED,
3  TodoItemStatus.NEEDS_ACTION: TodoStatus.NEEDS_ACTION,
4 }

Definition at line 40 of file todo.py.

◆ PRODID

string homeassistant.components.local_todo.todo.PRODID = "-//homeassistant.io//local_todo 2.0//EN"

Definition at line 31 of file todo.py.

◆ PRODID_REQUIRES_MIGRATION

string homeassistant.components.local_todo.todo.PRODID_REQUIRES_MIGRATION = "-//homeassistant.io//local_todo 1.0//EN"

Definition at line 32 of file todo.py.