diff options
Diffstat (limited to 'applications/luci-statistics')
4 files changed, 11 insertions, 12 deletions
diff --git a/applications/luci-statistics/src/model/cbi/admin_statistics/dns.lua b/applications/luci-statistics/src/model/cbi/admin_statistics/dns.lua index 02896d8e4..ed71a55a3 100644 --- a/applications/luci-statistics/src/model/cbi/admin_statistics/dns.lua +++ b/applications/luci-statistics/src/model/cbi/admin_statistics/dns.lua @@ -13,7 +13,7 @@ $Id$ ]]-- -require("ffluci.model.uci") +require("ffluci.sys") m = Map("luci_statistics", "DNS Plugin", @@ -30,10 +30,8 @@ enable.default = 0 interfaces = s:option( ListValue, "Interface", "Folgende Schnittstelle überwachen:" ) interfaces:depends( "enable", 1 ) interfaces:value("any") -for k, v in pairs(ffluci.model.uci.sections("network")) do - if v[".type"] == "interface" and k ~= "loopback" then - interfaces:value(k) - end +for k, v in pairs(ffluci.sys.net.devices()) do + interfaces:value(v) end -- collectd_dns.ignoresources (IgnoreSource) diff --git a/applications/luci-statistics/src/model/cbi/admin_statistics/email.lua b/applications/luci-statistics/src/model/cbi/admin_statistics/email.lua index 49c11de11..7b259e829 100644 --- a/applications/luci-statistics/src/model/cbi/admin_statistics/email.lua +++ b/applications/luci-statistics/src/model/cbi/admin_statistics/email.lua @@ -27,7 +27,7 @@ enable.default = 0 -- collectd_email.socketfile (SocketFile) socketfile = s:option( Value, "SocketFile", "Pfad für den Unix-Socket" ) -socketfile.default = "/var/run/collect-email.socket" +socketfile.default = "/var/run/collect-email.sock" socketfile:depends( "enable", 1 ) -- collectd_email.socketgroup (SocketGroup) diff --git a/applications/luci-statistics/src/model/cbi/admin_statistics/interface.lua b/applications/luci-statistics/src/model/cbi/admin_statistics/interface.lua index e7e3042a9..5acd4e93c 100644 --- a/applications/luci-statistics/src/model/cbi/admin_statistics/interface.lua +++ b/applications/luci-statistics/src/model/cbi/admin_statistics/interface.lua @@ -13,6 +13,9 @@ $Id$ ]]-- +require("ffluci.sys") + + m = Map("luci_statistics", "Interface Plugin", [[Das Interface-Plugin sammelt Informationen zum Netzwerkverkehr auf den einzelnen Schnittstellen.]]) @@ -27,10 +30,8 @@ enable.default = 0 interfaces = s:option( MultiValue, "Interfaces", "Überwachte Schnittstellen", "mehrere Einträge mit Strg selektieren" ) interfaces.widget = "select" interfaces:depends( "enable", 1 ) -for k, v in pairs(ffluci.model.uci.sections("network")) do - if v[".type"] == "interface" and k ~= "loopback" then - interfaces:value(k) - end +for k, v in pairs(ffluci.sys.net.devices()) do + interfaces:value(v) end -- collectd_interface.ignoreselected (IgnoreSelected) diff --git a/applications/luci-statistics/src/model/cbi/admin_statistics/netlink.lua b/applications/luci-statistics/src/model/cbi/admin_statistics/netlink.lua index 9e1b86d4d..478560f97 100644 --- a/applications/luci-statistics/src/model/cbi/admin_statistics/netlink.lua +++ b/applications/luci-statistics/src/model/cbi/admin_statistics/netlink.lua @@ -33,7 +33,7 @@ interfaces.optional = true interfaces:depends( "enable", 1 ) interfaces:value("") for i, v in ipairs(ffluci.sys.net.devices()) do - interfaces:value(v) + interfaces:value(v) end -- collectd_netlink.verboseinterfaces (VerboseInterface) @@ -43,7 +43,7 @@ verboseinterfaces.optional = true verboseinterfaces:depends( "enable", 1 ) verboseinterfaces:value("") for i, v in ipairs(ffluci.sys.net.devices()) do - verboseinterfaces:value(v) + verboseinterfaces:value(v) end -- collectd_netlink.qdiscs (QDisc) |