mirror of
https://github.com/home-assistant/core.git
synced 2025-07-09 22:37:11 +00:00
parent
28da10ad0d
commit
844ff30a60
@ -17,6 +17,7 @@ from .const import (
|
||||
ATTR_SENSOR_ENTITY_CATEGORY,
|
||||
ATTR_SENSOR_ICON,
|
||||
ATTR_SENSOR_STATE,
|
||||
ATTR_SENSOR_STATE_CLASS,
|
||||
SIGNAL_SENSOR_UPDATE,
|
||||
)
|
||||
from .helpers import device_info
|
||||
@ -44,6 +45,7 @@ class MobileAppEntity(RestoreEntity):
|
||||
"""Update the entity from the config."""
|
||||
config = self._config
|
||||
self._attr_device_class = config.get(ATTR_SENSOR_DEVICE_CLASS)
|
||||
self._attr_state_class = config.get(ATTR_SENSOR_STATE_CLASS)
|
||||
self._attr_extra_state_attributes = config[ATTR_SENSOR_ATTRIBUTES]
|
||||
self._attr_icon = config[ATTR_SENSOR_ICON]
|
||||
self._attr_entity_category = config.get(ATTR_SENSOR_ENTITY_CATEGORY)
|
||||
|
Loading…
x
Reference in New Issue
Block a user