Add extra attributes for device scanner, Nmap and Unifi (IP, SSID, etc.) (#13673)
* Start of development * Add extra attributes from unifi scanner * Store IP of the device in the state attributes with nmap * Allow not defining get_extra_attributes method in derived classes
This commit is contained in:
1 parent
517fb2e983
commit
36a663adeb
3 files changed
+39
-1
No files matched your search
@@ -122,3 +122,9 @@ class UnifiScanner(DeviceScanner):
|
||||
name = client.get('name') or client.get('hostname')
|
||||
_LOGGER.debug("Device mac %s name %s", device, name)
|
||||
return name
|
||||
|
||||
def get_extra_attributes(self, device):
|
||||
"""Return the extra attributes of the device."""
|
||||
client = self._clients.get(device, {})
|
||||
_LOGGER.debug("Device mac %s attributes %s", device, client)
|
||||
return client
|
||||
Reference in new issue
Block a user