summaryrefslogtreecommitdiffstats
path: root/usr/local/www/status_rrd_graph.php
diff options
context:
space:
mode:
authorErik Fonnesbeck <efonnes@gmail.com>2010-08-23 21:11:25 -0600
committerErik Fonnesbeck <efonnes@gmail.com>2010-08-23 21:11:25 -0600
commit9cd5e6f516437e9b31e2fc17826d463ca78381bf (patch)
tree81a0ab9887bd890de5c504950068b921196b870c /usr/local/www/status_rrd_graph.php
parent85a4aab6125b7cd79d1c5a697c1f47ce473d9785 (diff)
downloadpfsense-9cd5e6f516437e9b31e2fc17826d463ca78381bf.zip
pfsense-9cd5e6f516437e9b31e2fc17826d463ca78381bf.tar.gz
Allow System: Throughput RRD graph to be displayed. Ticket #715
Diffstat (limited to 'usr/local/www/status_rrd_graph.php')
-rwxr-xr-xusr/local/www/status_rrd_graph.php12
1 files changed, 8 insertions, 4 deletions
diff --git a/usr/local/www/status_rrd_graph.php b/usr/local/www/status_rrd_graph.php
index e1ee2b2..dd659c7 100755
--- a/usr/local/www/status_rrd_graph.php
+++ b/usr/local/www/status_rrd_graph.php
@@ -175,6 +175,9 @@ $dbheader = array("allgraphs-traffic.rrd",
"outbound-packets.rrd",
"outbound-traffic.rrd");
+/* additional menu choices for the custom tab */
+$dbheader_custom = array("system-throughput.rrd");
+
foreach($databases as $database) {
if(stristr($database, "-wireless")) {
$wireless = true;
@@ -191,6 +194,7 @@ foreach($databases as $database) {
}
/* append the existing array to the header */
$ui_databases = array_merge($dbheader, $databases);
+$custom_databases = array_merge($dbheader_custom, $databases);
$styles = array('inverse' => gettext('Inverse'),
'absolute' => gettext('Absolute'));
@@ -336,7 +340,7 @@ function get_dates($curperiod, $graph) {
<?php
if($curcat == "custom") {
- foreach ($databases as $db => $database) {
+ foreach ($custom_databases as $db => $database) {
$optionc = split("-", $database);
$search = array("-", ".rrd", $optionc);
$replace = array(" :: ", "", $friendly);
@@ -420,7 +424,7 @@ function get_dates($curperiod, $graph) {
<?php
$curdatabase = $curoption;
$graph = "custom-$curdatabase";
- if(in_array($curdatabase, $databases)) {
+ if(in_array($curdatabase, $custom_databases)) {
echo "<tr><td colspan=2 class=\"list\">\n";
echo "<IMG BORDER='0' name='{$graph}-{$curoption}-{$curdatabase}' ";
echo "id='{$graph}-{$curoption}-{$curdatabase}' ALT=\"$prettydb Graph\" ";
@@ -463,7 +467,7 @@ function get_dates($curperiod, $graph) {
continue 2;
}
}
- if(in_array($curdatabase, $databases)) {
+ if(in_array($curdatabase, $ui_databases)) {
$dates = get_dates($curperiod, $graph);
$start = $dates['start'];
$end = $dates['end'];
@@ -489,7 +493,7 @@ function get_dates($curperiod, $graph) {
<?php
foreach($graphs as $graph) {
/* check which databases are valid for our category */
- foreach($databases as $curdatabase) {
+ foreach($ui_databases as $curdatabase) {
if(! stristr($curdatabase, $curcat)) {
continue;
}
OpenPOWER on IntegriCloud