Merge pull request #996 from laf/port-relationship

Added flag to disable port relationship in ports list for a device
This commit is contained in:
Daniel Preussker
2015-05-14 11:46:42 +00:00
2 changed files with 4 additions and 3 deletions

View File

@@ -143,7 +143,7 @@ if (strpos($port['label'], "oopback") === false && !$graph_type)
unset($br);
if ($port_details)
if ($port_details && $config['enable_port_relationship'] === TRUE)
{ // Show which other devices are on the same subnet as this interface
foreach (dbFetchRows("SELECT `ipv4_network_id` FROM `ipv4_addresses` WHERE `port_id` = ? AND `ipv4_address` NOT LIKE '127.%'", array($port['port_id'])) as $net)
{
@@ -187,7 +187,7 @@ if (strpos($port['label'], "oopback") === false && !$graph_type)
}
}
if ($port_details)
if ($port_details && $config['enable_port_relationship'] === TRUE)
{
foreach ($int_links as $int_link)
{
@@ -208,7 +208,7 @@ if (strpos($port['label'], "oopback") === false && !$graph_type)
# unset($int_links, $int_links_v6, $int_links_v4, $int_links_phys, $br);
}
if ($port_details)
if ($port_details && $config['enable_port_relationship'] === TRUE)
{
foreach (dbFetchRows("SELECT * FROM `pseudowires` WHERE `port_id` = ?", array($port['port_id'])) as $pseudowire)
{