mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
webui: ports pages cleanup (#8040)
* ports pages cleanup * removed useless html span tag
This commit is contained in:
@@ -38,7 +38,7 @@ foreach ($menu_options as $option => $text) {
|
||||
}
|
||||
$sep = " | ";
|
||||
}
|
||||
$displayLists .= ' <span style="font-weight: bold;">Graphs</span> »';
|
||||
$displayLists .= ' <span style="font-weight: bold;">Graphs</span> » ';
|
||||
|
||||
$menu_options = array('bits' => 'Bits',
|
||||
'upkts' => 'Unicast Packets',
|
||||
|
@@ -1,12 +1,12 @@
|
||||
<?php
|
||||
|
||||
foreach ($ports as $port) {
|
||||
if (is_integer($row / 2)) {
|
||||
$row_colour = $list_colour_a;
|
||||
} else {
|
||||
$row_colour = $list_colour_b;
|
||||
}
|
||||
echo '<div class="panel panel-default panel-condensed">';
|
||||
echo '<div class="panel-heading">';
|
||||
echo $displayLists;
|
||||
echo '</div>';
|
||||
echo '<div class="panel-body">';
|
||||
|
||||
foreach ($ports as $port) {
|
||||
$speed = humanspeed($port['ifSpeed']);
|
||||
$type = humanmedia($port['ifType']);
|
||||
|
||||
@@ -58,14 +58,7 @@ foreach ($ports as $port) {
|
||||
echo "<div style='display: block; padding: 1px; margin: 2px; min-width: ".$width_div.'px; max-width:'.$width_div."px; min-height:180px; max-height:180px; text-align: center; float: left; background-color: #f5f5f5;'>";
|
||||
echo overlib_link($link, $graph, $overlib_content);
|
||||
echo '</div>';
|
||||
}
|
||||
}
|
||||
|
||||
// echo("<div style='display: block; padding: 1px; margin: 2px; min-width: 393px; max-width:393px; min-height:180px; max-height:180px; text-align: center; float: left; background-color: #f5f5f5;'>
|
||||
// <a href='".generate_port_url($port)."/' onmouseover=\"return overlib('\
|
||||
// <div style=\'font-size: 16px; padding:5px; font-weight: bold; color: #e5e5e5;\'>".$device['hostname']." - ".$port['ifDescr']."</div>\
|
||||
// <img src=\'graph.php?type=$graph_type&id=".$port['port_id']."&from=".$config['time']['day']."&to=".$config['time']['now']."&width=450&height=150&title=yes\'>\
|
||||
// ', 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']['day']."&to=".$config['time']['now']."&width=315&height=110&legend=no&title=yes'>
|
||||
// </a>
|
||||
// </div>");
|
||||
}//end if
|
||||
}//end foreach
|
||||
echo '</div>';
|
||||
|
@@ -30,11 +30,10 @@ if ($vars['errors']) {
|
||||
<?php echo $displayLists; ?>
|
||||
</div>
|
||||
<div class="table-responsive">
|
||||
<table id="ports" class="table table-condensed table-hover">
|
||||
<table id="ports" class="table table-condensed table-hover table-striped">
|
||||
<thead>
|
||||
<tr>
|
||||
<th data-column-id="status"></th>
|
||||
<th data-column-id="device">Device</th>
|
||||
<th data-column-id="device" data-formatter="device">Device</th>
|
||||
<th data-column-id="port"<?php echo $sort ?>>Port</th>
|
||||
<th data-column-id="ifLastChange" data-converter="duration">Status Changed</th>
|
||||
<th data-column-id="ifConnectorPresent" data-visible="false">Connected</th>
|
||||
@@ -96,6 +95,11 @@ var grid = $("#ports").bootgrid({
|
||||
}
|
||||
}
|
||||
},
|
||||
formatters: {
|
||||
'device': function (column, row) {
|
||||
return "<span class='alert-status " + row.status + "' style='float:left;margin-right:10px;'></span>" + row.device + "";
|
||||
}
|
||||
},
|
||||
templates: {
|
||||
search: "" // hide the generic search
|
||||
},
|
||||
|
Reference in New Issue
Block a user