mirror of
https://github.com/home-assistant/core
synced 2024-10-04 07:58:43 +02:00
Use UnitOfTemperature in devolo Home Control (#81923)
This commit is contained in:
parent
e6d1a4a422
commit
97ebe59584
@ -8,13 +8,12 @@ from devolo_home_control_api.homecontrol import HomeControl
|
||||
|
||||
from homeassistant.components.climate import (
|
||||
ATTR_TEMPERATURE,
|
||||
TEMP_CELSIUS,
|
||||
ClimateEntity,
|
||||
ClimateEntityFeature,
|
||||
HVACMode,
|
||||
)
|
||||
from homeassistant.config_entries import ConfigEntry
|
||||
from homeassistant.const import PRECISION_HALVES, PRECISION_TENTHS
|
||||
from homeassistant.const import PRECISION_HALVES, PRECISION_TENTHS, UnitOfTemperature
|
||||
from homeassistant.core import HomeAssistant
|
||||
from homeassistant.helpers.entity_platform import AddEntitiesCallback
|
||||
|
||||
@ -68,7 +67,7 @@ class DevoloClimateDeviceEntity(DevoloMultiLevelSwitchDeviceEntity, ClimateEntit
|
||||
self._attr_precision = PRECISION_TENTHS
|
||||
self._attr_supported_features = ClimateEntityFeature.TARGET_TEMPERATURE
|
||||
self._attr_target_temperature_step = PRECISION_HALVES
|
||||
self._attr_temperature_unit = TEMP_CELSIUS
|
||||
self._attr_temperature_unit = UnitOfTemperature.CELSIUS
|
||||
|
||||
@property
|
||||
def current_temperature(self) -> float | None:
|
||||
|
Loading…
Reference in New Issue
Block a user