From 2103b25243715930aae8019b0ee2e8a16b7418fe Mon Sep 17 00:00:00 2001 From: Erik Fonnesbeck Date: Mon, 23 Aug 2010 23:24:22 -0600 Subject: Skip the placeholder databases when outbound is selected, too. Also don't check the name against the gateway list on anything but the quality tab. --- usr/local/www/status_rrd_graph.php | 22 +++++++++++++++++++--- 1 file changed, 19 insertions(+), 3 deletions(-) (limited to 'usr/local') diff --git a/usr/local/www/status_rrd_graph.php b/usr/local/www/status_rrd_graph.php index 3630bba..1daae30 100755 --- a/usr/local/www/status_rrd_graph.php +++ b/usr/local/www/status_rrd_graph.php @@ -444,11 +444,19 @@ function get_dates($curperiod, $graph) { $replace = array(" :: ", "", $friendly); switch($curoption) { case "outbound": + /* make sure we do not show the placeholder databases in the outbound view */ + if((stristr($curdatabase, "outbound")) || (stristr($curdatabase, "allgraphs"))) { + continue 2; + } /* only show interfaces with a gateway */ $optionc = "$optionc[0]"; if(!interface_has_gateway($optionc)) { - if(!isset($gateways_arr)) - $gateways_arr = return_gateways_array(); + if(!isset($gateways_arr)) { + if(preg_match("/quality/i", $curdatabase)) + $gateways_arr = return_gateways_array(); + else + $gateways_arr = array(); + } $found_gateway = false; foreach ($gateways_arr as $gw) { if ($gw['name'] == $optionc) { @@ -511,10 +519,18 @@ function get_dates($curperiod, $graph) { $replace = array(" :: ", "", $friendly); switch($curoption) { case "outbound": + /* make sure we do not show the placeholder databases in the outbound view */ + if((stristr($curdatabase, "outbound")) || (stristr($curdatabase, "allgraphs"))) { + continue 2; + } + /* only show interfaces with a gateway */ $optionc = "$optionc[0]"; if(!interface_has_gateway($optionc)) { if(!isset($gateways_arr)) - $gateways_arr = return_gateways_array(); + if(preg_match("/quality/i", $curdatabase)) + $gateways_arr = return_gateways_array(); + else + $gateways_arr = array(); $found_gateway = false; foreach ($gateways_arr as $gw) { if ($gw['name'] == $optionc) { -- cgit v1.1