2008-10-28 22:06:00 +00:00
|
|
|
<?php
|
|
|
|
|
2012-05-29 13:08:01 +00:00
|
|
|
// fixme new url format
|
2015-07-10 13:36:21 +02:00
|
|
|
if (is_integer($i / 2)) {
|
|
|
|
$bg_colour = $list_colour_a;
|
2016-08-18 20:28:22 -05:00
|
|
|
} else {
|
2015-07-10 13:36:21 +02:00
|
|
|
$bg_colour = $list_colour_b;
|
|
|
|
}
|
2012-05-29 13:08:01 +00:00
|
|
|
|
2015-07-10 13:36:21 +02:00
|
|
|
echo "<tr bgcolor='$bg_colour'>";
|
2008-10-28 22:06:00 +00:00
|
|
|
|
2015-07-10 13:36:21 +02:00
|
|
|
echo "<td width=200 class=list-large><a href='routing/vrf/".$vrf['mplsVpnVrfRouteDistinguisher']."/'>".$vrf['vrf_name'].'</a></td>';
|
|
|
|
echo '<td width=150 class=box-desc>'.$vrf['mplsVpnVrfDescription'].'</td>';
|
|
|
|
echo '<td width=100 class=box-desc>'.$vrf['mplsVpnVrfRouteDistinguisher'].'</td>';
|
2008-10-28 22:06:00 +00:00
|
|
|
|
2015-07-10 13:36:21 +02:00
|
|
|
echo '<td class="list-bold">';
|
|
|
|
foreach (dbFetchRows('SELECT * FROM ports WHERE `device_id` = ? AND `ifVrf` = ?', array($device['device_id'], $vrf['vrf_id'])) as $port) {
|
2017-04-04 08:08:23 +01:00
|
|
|
$port = cleanPort($port, $device);
|
2015-07-10 13:36:21 +02:00
|
|
|
if ($vars['view'] == 'graphs') {
|
|
|
|
$graph_type = 'port_'.$vars['graph'];
|
|
|
|
echo "<div style='display: block; padding: 2px; margin: 2px; min-width: 139px; max-width:139px; min-height:85px; max-height:85px; text-align: center; float: left; background-color: #e9e9e9;'>
|
2009-08-07 11:53:10 +00:00
|
|
|
<div style='font-weight: bold;'>".makeshortif($port['ifDescr'])."</div>
|
2015-07-10 13:36:21 +02:00
|
|
|
<a href='device/".$device['device_id'].'/port/'.$port['port_id']."/' onmouseover=\"return overlib('\
|
|
|
|
<div style=\'font-size: 16px; padding:5px; font-weight: bold; color: #e5e5e5;\'>".$device['hostname'].' - '.$port['ifDescr'].'</div>\
|
2017-04-04 08:08:23 +01:00
|
|
|
'.$port['ifAlias']." \
|
2015-07-10 13:36:21 +02:00
|
|
|
<img src=\'graph.php?type=$graph_type&id=".$port['port_id'].'&from='.$config['time']['twoday'].'&to='.$config['time']['now']."&width=450&height=150\'>\
|
|
|
|
', CENTER, LEFT, FGCOLOR, '#e5e5e5', BGCOLOR, '#e5e5e5', WIDTH, 400, HEIGHT, 150);\" onmouseout=\"return nd();\" >"."<img src='graph.php?type=$graph_type&id=".$port['port_id'].'&from='.$config['time']['twoday'].'&to='.$config['time']['now']."&width=132&height=40&legend=no'>
|
2009-08-07 11:53:10 +00:00
|
|
|
</a>
|
2017-04-04 08:08:23 +01:00
|
|
|
<div style='font-size: 9px;'>".substr(short_port_descr($port['ifAlias']), 0, 22).'</div>
|
2015-07-10 13:36:21 +02:00
|
|
|
</div>';
|
2016-08-18 20:28:22 -05:00
|
|
|
} else {
|
2015-07-10 13:36:21 +02:00
|
|
|
echo $vrf['port_sep'].generate_port_link($port, makeshortif($port['ifDescr']));
|
|
|
|
$vrf['port_sep'] = ', ';
|
|
|
|
}
|
2008-10-28 22:06:00 +00:00
|
|
|
}
|
2011-04-06 13:54:50 +00:00
|
|
|
|
2015-07-10 13:36:21 +02:00
|
|
|
echo '</td>';
|
|
|
|
echo '</tr>';
|