added connections to accounting sensor #17

This commit is contained in:
tomaae 2020-04-10 12:26:48 +02:00
parent 8bfa30b3a1
commit 6a8103ee47

View file

@ -391,6 +391,8 @@ class MikrotikAccountingSensor(MikrotikControllerSensor):
def device_info(self):
"""Return a accounting description for device registry."""
info = {
"connections": {
(CONNECTION_NETWORK_MAC, self._data["mac-address"])},
"manufacturer": self._ctrl.data["resource"]["platform"],
"model": self._ctrl.data["resource"]["board-name"],
"name": f"{self._inst} {self._data['host-name']}",