luci-app-statistics: cleanup ping definitions

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
This commit is contained in:
Florian Eckert 2019-09-13 14:01:36 +02:00
parent 00fc5548ff
commit cb252b2c03

View file

@ -9,25 +9,44 @@ end
function rrdargs( graph, plugin, plugin_instance, dtype )
return {
-- Ping roundtrip time
{ title = "%H: ICMP Round Trip Time",
local ping = {
title = "%H: ICMP Round Trip Time",
vlabel = "ms",
number_format = "%5.1lf ms",
data = {
sources = { ping = { "value" } },
options = { ping__value = {
noarea = true, overlay = true, title = "%di" } }
} },
sources = {
ping = {
"value"
}
},
options = {
ping__value = {
noarea = true,
overlay = true,
title = "%di"
}
}
}
}
-- Ping droprate
{ title = "%H: ICMP Drop Rate",
local droprate = {
title = "%H: ICMP Drop Rate",
vlabel = "%",
number_format = "%5.2lf %%",
data = {
types = { "ping_droprate" },
options = { ping_droprate = {
noarea = true, overlay = true, title = "%di", transform_rpn = "100,*" } }
} }
types = {
"ping_droprate"
},
options = {
ping_droprate = {
noarea = true,
overlay = true,
title = "%di",
transform_rpn = "100,*"
}
}
}
}
return { ping, droprate }
end