mirror of
https://github.com/stylersnico/librenms.git
synced 2026-07-28 08:02:41 +02:00
Some small changes
This commit is contained in:
@@ -37,7 +37,8 @@ $tmp_ids = array();
|
||||
$tmp_links = array();
|
||||
$tmp_link_ids = array();
|
||||
|
||||
$ports = dbFetchRows("SELECT
|
||||
if (in_array('mac',$config['map_items'])) {
|
||||
$ports = dbFetchRows("SELECT
|
||||
`D1`.`device_id` AS `local_device_id`,
|
||||
`D1`.`os` AS `local_os`,
|
||||
`D1`.`hostname` AS `local_hostname`,
|
||||
@@ -73,8 +74,10 @@ $ports = dbFetchRows("SELECT
|
||||
$sql
|
||||
GROUP BY `P1`.`port_id`,`P2`.`port_id`
|
||||
", $sql_array);
|
||||
}
|
||||
|
||||
$devices = dbFetchRows("SELECT
|
||||
if (in_array('xdp', $config['map_items'])) {
|
||||
$devices = dbFetchRows("SELECT
|
||||
`D1`.`device_id` AS `local_device_id`,
|
||||
`D1`.`os` AS `local_os`,
|
||||
`D1`.`hostname` AS `local_hostname`,
|
||||
@@ -112,6 +115,7 @@ $devices = dbFetchRows("SELECT
|
||||
$sql
|
||||
GROUP BY `P1`.`port_id`,`P2`.`port_id`
|
||||
", $sql_array);
|
||||
}
|
||||
|
||||
$list = array_merge($ports,$devices);
|
||||
|
||||
@@ -218,7 +222,7 @@ var options = {
|
||||
face: 'sans',
|
||||
background: 'white',
|
||||
strokeWidth:3,
|
||||
align: 'bottom'
|
||||
align: 'horizontal'
|
||||
}
|
||||
},
|
||||
"physics": {
|
||||
|
||||
@@ -319,6 +319,7 @@ $config['map_legend'] = array(
|
||||
'90' => '#ff6600',
|
||||
'100' => '#ff0000',
|
||||
);
|
||||
$config['map_items'] = array('xdp','mac');
|
||||
|
||||
// Device page options
|
||||
$config['show_overview_tab'] = true;
|
||||
|
||||
Reference in New Issue
Block a user