luci-app-statistics: add new item callback for menu entry
[project/luci.git] / applications / luci-app-statistics / luasrc / statistics / rrdtool / definitions / splash_leases.lua
1 -- Copyright 2013 Freifunk Augsburg / Michael Wendland <michael@michiwend.com>
2 -- Licensed to the public under the Apache License 2.0.
3
4 module("luci.statistics.rrdtool.definitions.splash_leases", package.seeall)
5
6 function item()
7 return luci.i18n.translate("Splash Leases")
8 end
9
10 function rrdargs( graph, plugin, plugin_instance, dtype )
11
12 return {
13 title = "%H: Splash Leases",
14 vlabel = "Active Clients",
15 y_min = "0",
16 number_format = "%5.1lf",
17 data = {
18 sources = {
19 splash_leases = { "leased", "whitelisted", "blacklisted" }
20 },
21
22 options = {
23 splash_leases__leased = { color = "00CC00", title = "Leased", overlay = false },
24 splash_leases__whitelisted = { color = "0000FF", title = "Whitelisted", overlay = false },
25 splash_leases__blacklisted = { color = "FF0000", title = "Blacklisted", overlay = false }
26 }
27 }
28 }
29
30 end