1
0
mirror of https://github.com/home-assistant/core.git synced 2025-12-22 20:09:35 +00:00
Files
core/homeassistant/components/saunum/entity.py
mettolen d1dea85cf5 Add Saunum integration (#155099)
Co-authored-by: Joostlek <joostlek@outlook.com>
2025-11-14 19:55:55 +01:00

28 lines
895 B
Python

"""Base entity for Saunum Leil Sauna Control Unit integration."""
from __future__ import annotations
from homeassistant.helpers.device_registry import DeviceInfo
from homeassistant.helpers.update_coordinator import CoordinatorEntity
from .const import DOMAIN
from .coordinator import LeilSaunaCoordinator
class LeilSaunaEntity(CoordinatorEntity[LeilSaunaCoordinator]):
"""Base entity for Saunum Leil Sauna."""
_attr_has_entity_name = True
def __init__(self, coordinator: LeilSaunaCoordinator) -> None:
"""Initialize the entity."""
super().__init__(coordinator)
entry_id = coordinator.config_entry.entry_id
self._attr_unique_id = entry_id
self._attr_device_info = DeviceInfo(
identifiers={(DOMAIN, entry_id)},
name="Saunum Leil",
manufacturer="Saunum",
model="Leil Touch Panel",
)