diff --git a/html/includes/graphs/customer/bits.inc.php b/html/includes/graphs/customer/bits.inc.php index 344d4fd916..64bd2e01ef 100644 --- a/html/includes/graphs/customer/bits.inc.php +++ b/html/includes/graphs/customer/bits.inc.php @@ -2,7 +2,7 @@ ## Generate a list of ports and then call the multi_bits grapher to generate from the list -$query = mysql_query("SELECT * FROM `ports` AS I, `devices` AS D WHERE `ifAlias` LIKE 'Cust: ".mres($_GET['cust'])."%' AND D.device_id = I.device_id"); +$query = mysql_query("SELECT * FROM `ports` AS I, `devices` AS D WHERE `port_descr_type` = 'cust' AND `port_descr_descr` = '".mres($_GET['id'])."' AND D.device_id = I.device_id"); while($int = mysql_fetch_array($query)) { if(is_file($config['rrd_dir'] . "/" . $int['hostname'] . "/" . safename($int['ifIndex'] . ".rrd"))) { $rrd_filenames[] = $config['rrd_dir'] . "/" . $int['hostname'] . "/" . safename($int['ifIndex'] . ".rrd"); diff --git a/html/includes/graphs/multiport/auth.inc.php b/html/includes/graphs/multiport/auth.inc.php new file mode 100644 index 0000000000..7a79bf4245 --- /dev/null +++ b/html/includes/graphs/multiport/auth.inc.php @@ -0,0 +1,16 @@ + + +### FIXME + +#if(is_numeric($id)) { +# $port = get_port_by_id($id); +# $device = device_by_id_cache($port['device_id']); +#} + +#$title = generatedevicelink($device); +#$title .= " :: Port ".generateiflink($port); + +$title = "Multi Port :: "; + + +?> diff --git a/html/includes/graphs/multi_bits.inc.php b/html/includes/graphs/multiport/bits.inc.php similarity index 76% rename from html/includes/graphs/multi_bits.inc.php rename to html/includes/graphs/multiport/bits.inc.php index 615ccd0e84..99e859f073 100644 --- a/html/includes/graphs/multi_bits.inc.php +++ b/html/includes/graphs/multiport/bits.inc.php @@ -1,11 +1,8 @@ diff --git a/html/includes/graphs/multi_bits_duo.inc.php b/html/includes/graphs/multiport/bits_duo.inc.php similarity index 100% rename from html/includes/graphs/multi_bits_duo.inc.php rename to html/includes/graphs/multiport/bits_duo.inc.php diff --git a/html/includes/graphs/multi_bits_separate.inc.php b/html/includes/graphs/multiport/bits_separate.inc.php similarity index 100% rename from html/includes/graphs/multi_bits_separate.inc.php rename to html/includes/graphs/multiport/bits_separate.inc.php diff --git a/html/includes/graphs/multi_bits_trio.inc.php b/html/includes/graphs/multiport/bits_trio.inc.php similarity index 100% rename from html/includes/graphs/multi_bits_trio.inc.php rename to html/includes/graphs/multiport/bits_trio.inc.php diff --git a/html/includes/print-interface.inc.php b/html/includes/print-interface.inc.php index 209baf9165..9954a13883 100644 --- a/html/includes/print-interface.inc.php +++ b/html/includes/print-interface.inc.php @@ -11,6 +11,8 @@ $if_id = $interface['interface_id']; +print_r($interface); + $interface = ifLabel($interface); if(!is_integer($i/2)) { $row_colour = $list_colour_a; } else { $row_colour = $list_colour_b; } diff --git a/html/pages/customers.inc.php b/html/pages/customers.inc.php index 0aa936d111..7ba965a16b 100644 --- a/html/pages/customers.inc.php +++ b/html/pages/customers.inc.php @@ -1,6 +1,6 @@ "); @@ -23,7 +23,7 @@ while($customer = mysql_fetch_array($cust_query)) { $i++; - $port_sql = "SELECT * FROM `ports` WHERE `port_descr_type` = 'Cust' AND `port_descr_descr` = '".$customer['port_descr_descr']."'"; + $port_sql = "SELECT * FROM `ports` WHERE `port_descr_type` = 'cust' AND `port_descr_descr` = '".$customer['port_descr_descr']."'"; $port_query = mysql_query($port_sql); $customer_name = $customer['port_descr_descr']; @@ -65,10 +65,10 @@ while($customer = mysql_fetch_array($cust_query)) { } echo("
Total Graph for ports of type : ".$types." | "); echo("|
"); - $graph_type = "multi_bits"; + $graph_type = "multiport_bits"; $interface['interface_id'] = $if_list; include("includes/print-interface-graphs.inc.php"); echo(" |
" . generateiflink($interface,$interface['ifAlias']) . " + | " . generateiflink($interface,$interface['port_descr_descr']) . " ".generatedevicelink($interface)." ".generateiflink($interface)." "); if(mysql_result(mysql_query("SELECT count(*) FROM mac_accounting WHERE interface_id = '".$interface['interface_id']."'"),0)){ |