Improve lists in integrations [I-K] (#113221)
This commit is contained in:
parent
dbb07c98e2
commit
7e0aac3feb
21 changed files with 136 additions and 143 deletions
|
@ -204,10 +204,10 @@ class KNXClimate(KnxEntity, ClimateEntity):
|
|||
"""Return the list of available operation/controller modes."""
|
||||
ha_controller_modes: list[HVACMode | None] = []
|
||||
if self._device.mode is not None:
|
||||
for knx_controller_mode in self._device.mode.controller_modes:
|
||||
ha_controller_modes.append(
|
||||
CONTROLLER_MODES.get(knx_controller_mode.value)
|
||||
)
|
||||
ha_controller_modes.extend(
|
||||
CONTROLLER_MODES.get(knx_controller_mode.value)
|
||||
for knx_controller_mode in self._device.mode.controller_modes
|
||||
)
|
||||
|
||||
if self._device.supports_on_off:
|
||||
if not ha_controller_modes:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue