* @copyright (C) 2006-2013 Adam Armstrong, (C) 2013-2019 Observium Limited * */ echo generate_box_open(); $dirs = array(); if(isset($port_attribs['sros_egress_queues'])) { $dirs['Egress'] = 'Egress'; } if(isset($port_attribs['sros_ingress_queues'])) { $dirs['Ingress'] = 'Ingress'; } $graphs = array('FwdInProfOcts' => 'Forwarded In-Profile Traffic', 'FwdOutProfOcts' => 'Forwarded Out-Profile Traffic', 'FwdInProfPkts' => 'Forwarded In-Profile Packets', 'FwdOutProfPkts' => 'Forwarded Out-Profile Packets', 'DroInProfOcts' => 'Dropped In-Profile Traffic', 'DroOutProfOcts' => 'Dropped Out-Profile Traffic', 'DroInProfPkts' => 'Dropped In-Profile Packets', 'DroOutProfPkts' => 'Dropped Out-Profile Packets'); $navbar['class'] = "navbar-narrow"; $navbar['brand'] = "CoS Queues"; foreach (array('overview' => 'Overview', 'queues' => 'Per-Queue') as $subview => $text) { if(!isset($vars['subview'])) { $vars['subview'] = $subview; } if ($vars['subview'] == $subview) { $navbar['options'][$subview]['class'] = "active"; } $navbar['options'][$subview]['url'] = generate_url($vars,array('subview'=>$subview)); $navbar['options'][$subview]['text'] = $text; } print_navbar($navbar); ?> '); } } } elseif($vars['subview'] == 'overview') { foreach($dirs as $dir) { foreach($graphs AS $type => $text) { echo(''); } } } ?>
'); echo('

'.ucfirst($dir).' '.$label.'

'); foreach(array('bits', 'pkts') as $metric) { $graph_array['type'] = "port_sros_queue"; $graph_array['queue'] = $queue; $graph_array['dir'] = $dir; $graph_array['metric'] = $metric; print_graph_row_port($graph_array, $port); unset($graph_array['queue']); unset($graph_array['dir']); unset($graph_array['metric']); } echo('
'); echo('

'.$dir.' '.$text.'

'); $graph_array['type'] = "port_sros_".$dir.$type; print_graph_row_port($graph_array, $port); echo('