diff options
author | Pim van den Berg | 2013-06-16 16:15:32 +0200 |
---|---|---|
committer | Pim van den Berg | 2013-06-16 16:16:33 +0200 |
commit | dc2735abe0b425ec54a2ca4611954b170031b0f1 (patch) | |
tree | 0897f8047a2a7c7c5d8232a238b89f4dc2c8d3c6 | |
parent | plugin/openvpn: fix traffic graph (diff) | |
download | apt-panopticon_cgp-dc2735abe0b425ec54a2ca4611954b170031b0f1.zip apt-panopticon_cgp-dc2735abe0b425ec54a2ca4611954b170031b0f1.tar.gz apt-panopticon_cgp-dc2735abe0b425ec54a2ca4611954b170031b0f1.tar.bz2 apt-panopticon_cgp-dc2735abe0b425ec54a2ca4611954b170031b0f1.tar.xz |
plugin/openvpn: add datasize support
-rw-r--r-- | plugin/openvpn.php | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/plugin/openvpn.php b/plugin/openvpn.php index 63111f5..0f1a2c2 100644 --- a/plugin/openvpn.php +++ b/plugin/openvpn.php | |||
@@ -24,7 +24,8 @@ switch(GET('t')) { | |||
24 | 'tx' => '00b000', | 24 | 'tx' => '00b000', |
25 | ); | 25 | ); |
26 | $obj->rrd_title = sprintf('Traffic (%s)', $obj->args['pinstance']); | 26 | $obj->rrd_title = sprintf('Traffic (%s)', $obj->args['pinstance']); |
27 | $obj->rrd_vertical = '%s per second'; | 27 | $obj->rrd_vertical = sprintf('%s per second', ucfirst($CONFIG['network_datasize'])); |
28 | $obj->scale = $CONFIG['network_datasize'] == 'bits' ? 8 : 1; | ||
28 | $obj->rrd_format = '%5.1lf%s'; | 29 | $obj->rrd_format = '%5.1lf%s'; |
29 | break; | 30 | break; |
30 | case 'users': | 31 | case 'users': |