Use centralized KnxEntity for all KNX platforms (#40381)
This commit is contained in:
parent
c13fbf795d
commit
3d6434be75
12 changed files with 206 additions and 338 deletions
|
@ -5,13 +5,13 @@ from xknx.devices import Notification as XknxNotification
|
|||
|
||||
from homeassistant.components.notify import BaseNotificationService
|
||||
|
||||
from . import DATA_KNX
|
||||
from .const import DOMAIN
|
||||
|
||||
|
||||
async def async_get_service(hass, config, discovery_info=None):
|
||||
"""Get the KNX notification service."""
|
||||
notification_devices = []
|
||||
for device in hass.data[DATA_KNX].xknx.devices:
|
||||
for device in hass.data[DOMAIN].xknx.devices:
|
||||
if isinstance(device, XknxNotification):
|
||||
notification_devices.append(device)
|
||||
return (
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue