diff options
Diffstat (limited to 'applications/luci-statistics/luasrc/statistics/datatree.lua')
-rw-r--r-- | applications/luci-statistics/luasrc/statistics/datatree.lua | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/applications/luci-statistics/luasrc/statistics/datatree.lua b/applications/luci-statistics/luasrc/statistics/datatree.lua index b494dc1084..d6de6fa217 100644 --- a/applications/luci-statistics/luasrc/statistics/datatree.lua +++ b/applications/luci-statistics/luasrc/statistics/datatree.lua @@ -192,3 +192,16 @@ function Instance.data_instances( self, plugin, instance, dtype ) return rv end + +function Instance.host_instances( self ) + local hosts_path = fs.glob(self._rrddir..'/*') + local hosts = { } + k = 1 + for v in hosts_path do + hosts[k] = fs.basename(v) + k=k+1 + end + + return hosts +end + |