From b42465f3fc6e282cf10627f0bc7c0c0cecc7d3c8 Mon Sep 17 00:00:00 2001 From: Florian Eckert Date: Mon, 4 Mar 2019 16:07:11 +0100 Subject: luci-app-statistics: rrdtool add canvas height option Added configuration parameters to also configure the height of the rrd images. config statistics 'rrdtool' option image_height '200' Signed-off-by: Florian Eckert --- applications/luci-app-statistics/luasrc/statistics/rrdtool.lua | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'applications/luci-app-statistics/luasrc/statistics') diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool.lua index b9f48a45bd..f827e92309 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool.lua @@ -26,6 +26,7 @@ function Graph.__init__( self, timespan, opts ) opts.rramax = opts.rramax or ( sections.collectd_rrdtool.RRAMax == "1" ) opts.host = opts.host or sections.collectd.Hostname or sys.hostname() opts.width = opts.width or sections.rrdtool.image_width or 400 + opts.height = opts.height or sections.rrdtool.image_height or 100 opts.rrdpath = opts.rrdpath or sections.collectd_rrdtool.DataDir or "/tmp/rrd" opts.imgpath = opts.imgpath or sections.rrdtool.image_path or "/tmp/rrdimg" opts.rrdpath = opts.rrdpath:gsub("/$","") @@ -40,7 +41,8 @@ function Graph.__init__( self, timespan, opts ) self.args = { "-a", "PNG", "-s", "NOW-" .. opts.timespan, - "-w", opts.width + "-w", opts.width, + "-h", opts.height } -- store options -- cgit v1.2.3 From 42a060a85255ac7e4ee33f5c16d3434c12a8f8fb Mon Sep 17 00:00:00 2001 From: Florian Eckert Date: Thu, 7 Mar 2019 10:26:12 +0100 Subject: luci-app-statistics: Diskfree graph show also percent view The Diskfree (df) plugin could also collect the values in percent if the option "ValuesPercentage" is set in the collectd configuration. This commit will check if "df_complex" / "percent_bytes" or both are collected by collectd and so will show the corrsponding graph. Signed-off-by: Florian Eckert --- .../luasrc/statistics/rrdtool/definitions/df.lua | 49 +++++++++++++++++++++- 1 file changed, 48 insertions(+), 1 deletion(-) (limited to 'applications/luci-app-statistics/luasrc/statistics') diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/df.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/df.lua index b5633c15ff..7a69e85ee5 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/df.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/df.lua @@ -5,7 +5,7 @@ module("luci.statistics.rrdtool.definitions.df", package.seeall) function rrdargs( graph, plugin, plugin_instance, dtype ) - return { + local df_complex = { title = "%H: Disk space usage on %pi", vlabel = "Bytes", number_format = "%5.1lf%sB", @@ -36,4 +36,51 @@ function rrdargs( graph, plugin, plugin_instance, dtype ) } } } + + local percent_bytes = { + title = "%H: Disk space usage on %pi", + vlabel = "Percent", + number_format = "%5.2lf %%", + + data = { + instances = { + percent_bytes = { "free", "used", "reserved" } + }, + + options = { + percent_bytes_free = { + color = "00ff00", + overlay = false, + title = "free" + }, + + percent_bytes_used = { + color = "ff0000", + overlay = false, + title = "used" + }, + + percent_bytes_reserved = { + color = "0000ff", + overlay = false, + title = "reserved" + } + } + } + } + + local types = graph.tree:data_types( plugin, plugin_instance ) + + local p = {} + for _, t in ipairs(types) do + if t == "percent_bytes" then + p[#p+1] = percent_bytes + end + + if t == "df_complex" then + p[#p+1] = df_complex + end + end + + return p end -- cgit v1.2.3 From cd1e8cc6b94ef9aed2199d69f54c94d0c0919605 Mon Sep 17 00:00:00 2001 From: Florian Eckert Date: Thu, 7 Mar 2019 14:50:17 +0100 Subject: luci-app-statistics: add new item callback for menu entry Add the item callback function to the rrdtool definitions. Signed-off-by: Florian Eckert --- .../luasrc/statistics/rrdtool/definitions/apcups.lua | 4 ++++ .../luasrc/statistics/rrdtool/definitions/conntrack.lua | 4 ++++ .../luasrc/statistics/rrdtool/definitions/contextswitch.lua | 4 ++++ .../luci-app-statistics/luasrc/statistics/rrdtool/definitions/cpu.lua | 4 ++++ .../luasrc/statistics/rrdtool/definitions/cpufreq.lua | 4 ++++ .../luasrc/statistics/rrdtool/definitions/curl.lua | 4 ++++ .../luci-app-statistics/luasrc/statistics/rrdtool/definitions/df.lua | 4 ++++ .../luasrc/statistics/rrdtool/definitions/disk.lua | 4 ++++ .../luci-app-statistics/luasrc/statistics/rrdtool/definitions/dns.lua | 4 ++++ .../luasrc/statistics/rrdtool/definitions/entropy.lua | 4 ++++ .../luasrc/statistics/rrdtool/definitions/interface.lua | 4 ++++ .../luasrc/statistics/rrdtool/definitions/iptables.lua | 4 ++++ .../luci-app-statistics/luasrc/statistics/rrdtool/definitions/irq.lua | 4 ++++ .../luasrc/statistics/rrdtool/definitions/iwinfo.lua | 4 ++++ .../luasrc/statistics/rrdtool/definitions/load.lua | 4 ++++ .../luasrc/statistics/rrdtool/definitions/memory.lua | 4 ++++ .../luasrc/statistics/rrdtool/definitions/netlink.lua | 4 ++++ .../luci-app-statistics/luasrc/statistics/rrdtool/definitions/nut.lua | 4 ++++ .../luasrc/statistics/rrdtool/definitions/olsrd.lua | 4 ++++ .../luasrc/statistics/rrdtool/definitions/openvpn.lua | 4 ++++ .../luasrc/statistics/rrdtool/definitions/ping.lua | 4 ++++ .../luasrc/statistics/rrdtool/definitions/processes.lua | 4 ++++ .../luasrc/statistics/rrdtool/definitions/sensors.lua | 4 ++++ .../luasrc/statistics/rrdtool/definitions/splash_leases.lua | 4 ++++ .../luasrc/statistics/rrdtool/definitions/tcpconns.lua | 4 ++++ .../luasrc/statistics/rrdtool/definitions/thermal.lua | 4 ++++ .../luasrc/statistics/rrdtool/definitions/uptime.lua | 4 ++++ 27 files changed, 108 insertions(+) (limited to 'applications/luci-app-statistics/luasrc/statistics') diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/apcups.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/apcups.lua index 37055f5861..637b5f9592 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/apcups.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/apcups.lua @@ -3,6 +3,10 @@ module("luci.statistics.rrdtool.definitions.apcups",package.seeall) +function item() + return luci.i18n.translate("APC UPS") +end + function rrdargs( graph, plugin, plugin_instance ) local lu = require("luci.util") diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/conntrack.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/conntrack.lua index 5212b736e2..d99dab0f01 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/conntrack.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/conntrack.lua @@ -3,6 +3,10 @@ module("luci.statistics.rrdtool.definitions.conntrack",package.seeall) +function item() + return luci.i18n.translate("Conntrack") +end + function rrdargs( graph, plugin, plugin_instance, dtype ) return { diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/contextswitch.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/contextswitch.lua index 6826e12adb..f9473e4406 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/contextswitch.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/contextswitch.lua @@ -2,6 +2,10 @@ module("luci.statistics.rrdtool.definitions.contextswitch",package.seeall) +function item() + return luci.i18n.translate("Context Switches") +end + function rrdargs( graph, plugin, plugin_instance, dtype ) return { diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/cpu.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/cpu.lua index ae0c0ce778..226c84ee96 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/cpu.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/cpu.lua @@ -3,6 +3,10 @@ module("luci.statistics.rrdtool.definitions.cpu",package.seeall) +function item() + return luci.i18n.translate("Processor") +end + function rrdargs( graph, plugin, plugin_instance, dtype ) return { diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/cpufreq.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/cpufreq.lua index 25a72d2285..08aab04b85 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/cpufreq.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/cpufreq.lua @@ -2,6 +2,10 @@ module("luci.statistics.rrdtool.definitions.cpufreq",package.seeall) +function item() + return luci.i18n.translate("CPU Frequency") +end + function rrdargs( graph, plugin, plugin_instance, dtype ) return { diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/curl.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/curl.lua index 2bbdfb08fb..4fde243ca9 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/curl.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/curl.lua @@ -3,6 +3,10 @@ module("luci.statistics.rrdtool.definitions.curl", package.seeall) +function item() + return luci.i18n.translate("cUrl") +end + function rrdargs( graph, plugin, plugin_instance, dtype ) return { diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/df.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/df.lua index 7a69e85ee5..fb732991ba 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/df.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/df.lua @@ -3,6 +3,10 @@ module("luci.statistics.rrdtool.definitions.df", package.seeall) +function item() + return luci.i18n.translate("Disk Space Usage") +end + function rrdargs( graph, plugin, plugin_instance, dtype ) local df_complex = { diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/disk.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/disk.lua index b6f7d6d5f8..29597ff989 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/disk.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/disk.lua @@ -3,6 +3,10 @@ module("luci.statistics.rrdtool.definitions.disk", package.seeall) +function item() + return luci.i18n.translate("Disk Usage") +end + function rrdargs( graph, plugin, plugin_instance, dtype ) return { diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/dns.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/dns.lua index cf96d8fbe1..0ff4c76858 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/dns.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/dns.lua @@ -3,6 +3,10 @@ module("luci.statistics.rrdtool.definitions.dns", package.seeall) +function item() + return luci.i18n.translate("DNS") +end + function rrdargs( graph, plugin, plugin_instance ) local traffic = { diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/entropy.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/entropy.lua index 3d30a70afb..01eb33f9b4 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/entropy.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/entropy.lua @@ -3,6 +3,10 @@ module("luci.statistics.rrdtool.definitions.entropy", package.seeall) +function item() + return luci.i18n.translate("Entropy") +end + function rrdargs( graph, plugin, plugin_instance, dtype ) return { diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/interface.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/interface.lua index 6ca65e539f..a4d4eefd53 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/interface.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/interface.lua @@ -3,6 +3,10 @@ module("luci.statistics.rrdtool.definitions.interface", package.seeall) +function item() + return luci.i18n.translate("Interfaces") +end + function rrdargs( graph, plugin, plugin_instance ) -- diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/iptables.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/iptables.lua index 9790e0e3d2..7218bfd441 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/iptables.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/iptables.lua @@ -3,6 +3,10 @@ module("luci.statistics.rrdtool.definitions.iptables", package.seeall) +function item() + return luci.i18n.translate("Firewall") +end + function rrdargs( graph, plugin, plugin_instance, dtype ) return { diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/irq.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/irq.lua index f61d0da646..56b4547b94 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/irq.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/irq.lua @@ -3,6 +3,10 @@ module("luci.statistics.rrdtool.definitions.irq", package.seeall) +function item() + return luci.i18n.translate("Interrupts") +end + function rrdargs( graph, plugin, plugin_instance, dtype ) return { diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/iwinfo.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/iwinfo.lua index 194afd6fc0..53f4c7a40c 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/iwinfo.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/iwinfo.lua @@ -3,6 +3,10 @@ module("luci.statistics.rrdtool.definitions.iwinfo", package.seeall) +function item() + return luci.i18n.translate("Wireless") +end + function rrdargs( graph, plugin, plugin_instance ) -- diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/load.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/load.lua index ce762dab46..b06c8c4148 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/load.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/load.lua @@ -3,6 +3,10 @@ module("luci.statistics.rrdtool.definitions.load", package.seeall) +function item() + return luci.i18n.translate("System Load") +end + function rrdargs( graph, plugin, plugin_instance, dtype ) return { diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/memory.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/memory.lua index 53d559c599..b05d31dc02 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/memory.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/memory.lua @@ -11,6 +11,10 @@ You may obtain a copy of the License at module("luci.statistics.rrdtool.definitions.memory",package.seeall) +function item() + return luci.i18n.translate("Memory") +end + function rrdargs( graph, plugin, plugin_instance, dtype ) return { diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/netlink.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/netlink.lua index f485048538..bdd3f2eb44 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/netlink.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/netlink.lua @@ -3,6 +3,10 @@ module("luci.statistics.rrdtool.definitions.netlink", package.seeall) +function item() + return luci.i18n.translate("Netlink") +end + function rrdargs( graph, plugin, plugin_instance ) -- diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/nut.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/nut.lua index dd93196902..84ca4951f9 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/nut.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/nut.lua @@ -2,6 +2,10 @@ module("luci.statistics.rrdtool.definitions.nut",package.seeall) +function item() + return luci.i18n.translate("UPS") +end + function rrdargs( graph, plugin, plugin_instance, dtype ) local voltages = { diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/olsrd.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/olsrd.lua index 481557bb7f..52bfbdf4f7 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/olsrd.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/olsrd.lua @@ -3,6 +3,10 @@ module("luci.statistics.rrdtool.definitions.olsrd", package.seeall) +function item() + return luci.i18n.translate("OLSRd") +end + function rrdargs( graph, plugin, plugin_instance, dtype ) local g = { } diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/openvpn.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/openvpn.lua index 876e871d1d..d16dbac908 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/openvpn.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/openvpn.lua @@ -3,6 +3,10 @@ module("luci.statistics.rrdtool.definitions.openvpn", package.seeall) +function item() + return luci.i18n.translate("OpenVPN") +end + function rrdargs( graph, plugin, plugin_instance ) local inst = plugin_instance:gsub("^openvpn%.(.+)%.status$", "%1") diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/ping.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/ping.lua index 5b575bfff2..c3645e408c 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/ping.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/ping.lua @@ -3,6 +3,10 @@ module("luci.statistics.rrdtool.definitions.ping", package.seeall) +function item() + return luci.i18n.translate("Ping") +end + function rrdargs( graph, plugin, plugin_instance, dtype ) return { diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/processes.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/processes.lua index 010ac1cd2e..4303824f34 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/processes.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/processes.lua @@ -3,6 +3,10 @@ module("luci.statistics.rrdtool.definitions.processes", package.seeall) +function item() + return luci.i18n.translate("Processes") +end + function rrdargs( graph, plugin, plugin_instance, dtype ) if plugin_instance == "" then diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/sensors.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/sensors.lua index b3119234a4..6e09a7b9f0 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/sensors.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/sensors.lua @@ -3,6 +3,10 @@ module("luci.statistics.rrdtool.definitions.sensors", package.seeall) +function item() + return luci.i18n.translate("Sensors") +end + function rrdargs( graph, plugin, plugin_instance ) return { diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/splash_leases.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/splash_leases.lua index 1a192ae6a6..5af998cfb5 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/splash_leases.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/splash_leases.lua @@ -3,6 +3,10 @@ module("luci.statistics.rrdtool.definitions.splash_leases", package.seeall) +function item() + return luci.i18n.translate("Splash Leases") +end + function rrdargs( graph, plugin, plugin_instance, dtype ) return { diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/tcpconns.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/tcpconns.lua index 7e7ed238f4..2d762f7a4c 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/tcpconns.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/tcpconns.lua @@ -3,6 +3,10 @@ module("luci.statistics.rrdtool.definitions.tcpconns", package.seeall) +function item() + return luci.i18n.translate("TCP Connections") +end + function rrdargs( graph, plugin, plugin_instance, dtype ) return { diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/thermal.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/thermal.lua index 532246465e..4a555a6054 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/thermal.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/thermal.lua @@ -2,6 +2,10 @@ module("luci.statistics.rrdtool.definitions.thermal",package.seeall) +function item() + return luci.i18n.translate("Thermal") +end + function rrdargs( graph, plugin, plugin_instance, dtype ) return { diff --git a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/uptime.lua b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/uptime.lua index a50e78491f..8d7d42bc6b 100644 --- a/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/uptime.lua +++ b/applications/luci-app-statistics/luasrc/statistics/rrdtool/definitions/uptime.lua @@ -11,6 +11,10 @@ You may obtain a copy of the License at module("luci.statistics.rrdtool.definitions.uptime", package.seeall) +function item() + return luci.i18n.translate("Uptime") +end + function rrdargs( graph, plugin, plugin_instance, dtype ) return { -- cgit v1.2.3