mirror of
https://github.com/home-assistant/core.git
synced 2025-07-23 05:07:41 +00:00
Use device class naming in keenteic ndms2 (#96701)
This commit is contained in:
parent
f0fb09c2be
commit
bd22cfc1d0
@ -28,16 +28,12 @@ class RouterOnlineBinarySensor(BinarySensorEntity):
|
||||
|
||||
_attr_device_class = BinarySensorDeviceClass.CONNECTIVITY
|
||||
_attr_should_poll = False
|
||||
_attr_has_entity_name = True
|
||||
|
||||
def __init__(self, router: KeeneticRouter) -> None:
|
||||
"""Initialize the APCUPSd binary device."""
|
||||
self._router = router
|
||||
|
||||
@property
|
||||
def name(self):
|
||||
"""Return the name of the online status sensor."""
|
||||
return f"{self._router.name} Online"
|
||||
|
||||
@property
|
||||
def unique_id(self) -> str:
|
||||
"""Return a unique identifier for this device."""
|
||||
|
Loading…
x
Reference in New Issue
Block a user