syntaxer run

git-svn-id: http://www.observium.org/svn/observer/trunk@2973 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
Tom Laermans
2012-04-06 15:01:58 +00:00
parent a4d35fed50
commit c95f4db6b8
4 changed files with 117 additions and 110 deletions

View File

@@ -61,7 +61,7 @@ if (isset($_GET['format']) && preg_match("/^[a-z]*$/", $_GET['format']))
$links = dbFetch("SELECT * from ports AS I, links AS L WHERE I.device_id = ? AND L.local_interface_id = I.interface_id ORDER BY L.remote_hostname", array($device['device_id']));
if (count($links))
{
if(!isset($locations[$device['location']])) { $locations[$device['location']] = $loc_count; $loc_count++; }
if (!isset($locations[$device['location']])) { $locations[$device['location']] = $loc_count; $loc_count++; }
$loc_id = $locations[$device['location']];
$map .= "\"".$device['hostname']."\" [fontsize=20, fillcolor=\"lightblue\", group=".$loc_id." URL=\"{$config['base_url']}/device/device=".$device['device_id']."/tab=map/\" shape=box3d]\n";
@@ -112,8 +112,8 @@ if (isset($_GET['format']) && preg_match("/^[a-z]*$/", $_GET['format']))
$dif['label'] = $link['remote_port'];
$dif['interface_id'] = $link['remote_hostname'] . $link['remote_port'];
}
if($where == "")
if ($where == "")
{
$map .= "\"$src\" -> \"" . $dst . "\" [weight=500000, arrowsize=0, len=0];\n";
$ifdone[$src][$sif['interface_id']] = 1;