Add config flow for binary_sensor group (#67802)
* Add config flow for binary_sensor group * Address review comments * Remove device class selection from flow * Update translation strings
This commit is contained in:
parent
e5523ef6b6
commit
5ae48bcf74
8 changed files with 137 additions and 60 deletions
|
@ -76,7 +76,7 @@ async def async_setup_platform(
|
|||
async_add_entities: AddEntitiesCallback,
|
||||
discovery_info: DiscoveryInfoType | None = None,
|
||||
) -> None:
|
||||
"""Set up the Group Cover platform."""
|
||||
"""Set up the Cover Group platform."""
|
||||
async_add_entities(
|
||||
[
|
||||
CoverGroup(
|
||||
|
@ -91,14 +91,14 @@ async def async_setup_entry(
|
|||
config_entry: ConfigEntry,
|
||||
async_add_entities: AddEntitiesCallback,
|
||||
) -> None:
|
||||
"""Initialize Light Switch config entry."""
|
||||
"""Initialize Cover Group config entry."""
|
||||
registry = er.async_get(hass)
|
||||
entity_id = er.async_validate_entity_ids(
|
||||
entities = er.async_validate_entity_ids(
|
||||
registry, config_entry.options[CONF_ENTITIES]
|
||||
)
|
||||
|
||||
async_add_entities(
|
||||
[CoverGroup(config_entry.entry_id, config_entry.title, entity_id)]
|
||||
[CoverGroup(config_entry.entry_id, config_entry.title, entities)]
|
||||
)
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue