mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
Fixed smokeping graphs (#10415)
* Remove duplicate code * Fix smokeping rrd file discovery * Fix Smokeping outgoing graphs
This commit is contained in:
committed by
Neil Lathwood
parent
592b2ea432
commit
164f3a096a
@@ -87,13 +87,14 @@ if ($vars['view'] == 'incoming') {
|
||||
$graph_array['type'] = 'device_smokeping_out_all_avg';
|
||||
$graph_array['device'] = $device['device_id'];
|
||||
echo '<tr><td>';
|
||||
echo '<h3>Aggregate</h3>';
|
||||
echo '<h3>Average</h3>';
|
||||
|
||||
include 'includes/html/print-graphrow.inc.php';
|
||||
|
||||
echo '</td></tr>';
|
||||
|
||||
$graph_array['type'] = 'device_smokeping_out_all';
|
||||
$graph_array['device'] = $device['device_id'];
|
||||
$graph_array['legend'] = 'no';
|
||||
echo '<tr><td>';
|
||||
echo '<h3>Aggregate</h3>';
|
||||
@@ -106,7 +107,7 @@ if ($vars['view'] == 'incoming') {
|
||||
|
||||
asort($smokeping_files['out'][$device['hostname']]);
|
||||
foreach ($smokeping_files['out'][$device['hostname']] as $host) {
|
||||
$hostname = str_replace('.rrd', '', $host);
|
||||
$hostname = str_replace('_', '.', str_replace('.rrd', '', $host));
|
||||
list($hostname) = explode('~', $hostname);
|
||||
$host = device_by_name($hostname);
|
||||
if (is_numeric($host['device_id'])) {
|
||||
|
||||
Reference in New Issue
Block a user