applications/luci-statistics: rework handling of index and detail graphs
[project/luci.git] / applications / luci-statistics / luasrc / statistics / rrdtool / definitions / netlink.lua
index 47594f0f80a641cc61c357d8f207e3fc4649934d..9313952518e16ebd4c5798ac9cfbfa5e0b7b30ce 100644 (file)
@@ -1,3 +1,18 @@
+--[[
+
+Luci statistics - netlink plugin diagram definition
+(c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net>
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+        http://www.apache.org/licenses/LICENSE-2.0
+
+$Id$
+
+]]--
+
 module("luci.statistics.rrdtool.definitions.netlink", package.seeall)
 
 function rrdargs( graph, plugin, plugin_instance )
@@ -6,12 +21,8 @@ function rrdargs( graph, plugin, plugin_instance )
        -- traffic diagram
        --
        local traffic = {
-
-               -- diagram title
-               title   = "Verkehr",
-
-               -- vertical label
-               vlabel  = "Bytes/s",
+               title = "%H: Netlink - Transfer on %pi",
+               vlabel = "Bytes/s",
 
                -- diagram data description
                data = {
@@ -41,12 +52,8 @@ function rrdargs( graph, plugin, plugin_instance )
        -- packet diagram
        --
        local packets = {
-
-               -- diagram title
-               title   = "Pakete",
-
-               -- vertical label
-               vlabel  = "Pakete/s",
+               title = "%H: Netlink - Packets on %pi",
+               vlabel = "Packets/s", detail = true,
 
                -- diagram data description
                data = {
@@ -115,12 +122,8 @@ function rrdargs( graph, plugin, plugin_instance )
        -- multicast diagram
        --
        local multicast = {
-
-               -- diagram title
-               title   = "Multicast-Pakete",
-
-               -- vertical label
-               vlabel  = "Pakete/s",
+               title = "%H: Netlink - Multicast on %pi",
+               vlabel = "Packets/s", detail = true,
 
                -- diagram data description
                data = {
@@ -143,12 +146,8 @@ function rrdargs( graph, plugin, plugin_instance )
        -- collision diagram
        --
        local collisions = {
-
-               -- diagram title
-               title   = "Paketkollisionen",
-
-               -- vertical label
-               vlabel  = "Kollisionen/s",
+               title = "%H: Netlink - Collisions on %pi",
+               vlabel = "Collisions/s", detail = true,
 
                -- diagram data description
                data = {
@@ -171,12 +170,8 @@ function rrdargs( graph, plugin, plugin_instance )
        -- error diagram
        --
        local errors = {
-
-               -- diagram title
-               title   = "TX/RX-Fehler",
-
-               -- vertical label
-               vlabel  = "Kollisionen/s",
+               title = "%H: Netlink - Errors on %pi",
+               vlabel = "Errors/s", detail = true,
 
                -- diagram data description
                data = {