mirror of
https://github.com/Andre0512/hon.git
synced 2025-05-20 09:55:06 -04:00
Add all wm and td sensors to wd
This commit is contained in:
parent
7b80acb6b9
commit
155b1ff91a
7 changed files with 102 additions and 179 deletions
|
@ -15,7 +15,7 @@ from homeassistant.core import callback
|
|||
from homeassistant.helpers.entity import EntityCategory
|
||||
|
||||
from .const import DOMAIN
|
||||
from .hon import HonEntity, HonCoordinator
|
||||
from .hon import HonEntity, HonCoordinator, unique_entities
|
||||
|
||||
NUMBERS: dict[str, tuple[NumberEntityDescription, ...]] = {
|
||||
"WM": (
|
||||
|
@ -85,16 +85,6 @@ NUMBERS: dict[str, tuple[NumberEntityDescription, ...]] = {
|
|||
translation_key="dry_time",
|
||||
),
|
||||
),
|
||||
"WD": (
|
||||
NumberEntityDescription(
|
||||
key="startProgram.delayTime",
|
||||
name="Delay Time",
|
||||
icon="mdi:timer-plus",
|
||||
entity_category=EntityCategory.CONFIG,
|
||||
native_unit_of_measurement=UnitOfTime.MINUTES,
|
||||
translation_key="delay_time",
|
||||
),
|
||||
),
|
||||
"OV": (
|
||||
NumberEntityDescription(
|
||||
key="startProgram.delayTime",
|
||||
|
@ -166,6 +156,8 @@ NUMBERS: dict[str, tuple[NumberEntityDescription, ...]] = {
|
|||
),
|
||||
}
|
||||
|
||||
NUMBERS["WD"] = unique_entities(NUMBERS["WM"], NUMBERS["TD"])
|
||||
|
||||
|
||||
async def async_setup_entry(hass, entry: ConfigEntry, async_add_entities) -> None:
|
||||
hon: Hon = hass.data[DOMAIN][entry.unique_id]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue