From feba48f69e4b5478017caa0641a04163701213ed Mon Sep 17 00:00:00 2001 From: Adam Amstrong Date: Tue, 3 Apr 2007 19:39:28 +0000 Subject: [PATCH] fix overview page a bit git-svn-id: http://www.observium.org/svn/observer/trunk@33 61d68cd4-352d-0410-923a-c4978735b2b8 --- html/includes/dev-overview.inc | 13 ++++--------- html/includes/print-event-short.inc | 13 ++++++------- 2 files changed, 10 insertions(+), 16 deletions(-) diff --git a/html/includes/dev-overview.inc b/html/includes/dev-overview.inc index c6b71620ef..54392313e7 100644 --- a/html/includes/dev-overview.inc +++ b/html/includes/dev-overview.inc @@ -42,7 +42,7 @@ echo("

Recent Events

while($entry = mysql_fetch_array($data)) { -include("includes/print-event.inc"); +include("includes/print-event-short.inc"); } echo(""); @@ -68,15 +68,10 @@ echo(" $sql = "SELECT * FROM interfaces WHERE host = '$id'"; $query = mysql_query($sql); while($data = mysql_fetch_array($query)) { - $up_admin = $data['up_admin']; - $up = $data['up']; - if ($up_admin == "down") { $status = "grey"; } - if ($up_admin == "up" && $up == "down") { $status = "red"; } - if ($up_admin == "up" && $up == "up") { $status = "blue"; } - echo("$ifbreak" . generateiflink($data, makeshortif(strtolower($data['if']))) . ""); - $ifbreak = ", "; + echo("$ifsep" . generateiflink($data, makeshortif(strtolower($data['if'])))); + $ifsep = ", "; } - unset($break); + unset($ifsep); echo(""); echo(""); diff --git a/html/includes/print-event-short.inc b/html/includes/print-event-short.inc index ad5f0d1736..fc22c782e2 100644 --- a/html/includes/print-event-short.inc +++ b/html/includes/print-event-short.inc @@ -14,18 +14,17 @@ if($bg == $list_colour_a) { $bg = $list_colour_b; } else { $bg=$list_colour_a; } echo(" - + $entry[humandate] "); $if['id'] = $entry[interface]; - $if['if'] = $interface; - echo(" + $if['if'] = makeshortif($interface); + echo(" " . generateiflink($if) . " - $icon - - $entry[message] - + " . + truncate($entry[message], 45) + . " ");