diff options
| author | artem <artem@97f52cf1-0a1b-0410-bd0e-c28be96e8082> | 2007-08-08 14:41:08 +0000 |
|---|---|---|
| committer | artem <artem@97f52cf1-0a1b-0410-bd0e-c28be96e8082> | 2007-08-08 14:41:08 +0000 |
| commit | 90ca4a571495b7356ccebf6e11dbb41880da2f65 (patch) | |
| tree | be9993f9a3300449461b4159a364881f16da67d0 /frontends | |
| parent | c1bfe9249054c66ed8470cca086f55bb12fbe976 (diff) | |
| download | zabbix-90ca4a571495b7356ccebf6e11dbb41880da2f65.tar.gz zabbix-90ca4a571495b7356ccebf6e11dbb41880da2f65.tar.xz zabbix-90ca4a571495b7356ccebf6e11dbb41880da2f65.zip | |
- merged rev. 4523:4526 of branches/1.4.2/ (Artem) [added trigger blink on status change during defined value, added defined value TRIGGER_BLINK_PERIOD]
git-svn-id: svn://svn.zabbix.com/trunk@4528 97f52cf1-0a1b-0410-bd0e-c28be96e8082
Diffstat (limited to 'frontends')
| -rw-r--r-- | frontends/php/include/defines.inc.php | 2 | ||||
| -rw-r--r-- | frontends/php/tr_status.php | 4 |
2 files changed, 4 insertions, 2 deletions
diff --git a/frontends/php/include/defines.inc.php b/frontends/php/include/defines.inc.php index 5e882a8d..8bc95333 100644 --- a/frontends/php/include/defines.inc.php +++ b/frontends/php/include/defines.inc.php @@ -203,6 +203,8 @@ define('TRIGGER_VALUE_FALSE',0); define('TRIGGER_VALUE_TRUE',1); define('TRIGGER_VALUE_UNKNOWN',2); + + define('TRIGGER_BLINK_PERIOD',1800); define('TRIGGER_SEVERITY_NOT_CLASSIFIED', 0); define('TRIGGER_SEVERITY_INFORMATION', 1); diff --git a/frontends/php/tr_status.php b/frontends/php/tr_status.php index 249329cf..d4b3a04d 100644 --- a/frontends/php/tr_status.php +++ b/frontends/php/tr_status.php @@ -295,7 +295,7 @@ include_once "include/page_header.php"; $cond=""; if($_REQUEST["hostid"] > 0) $cond=" and h.hostid=".$_REQUEST["hostid"]." "; - if($onlytrue=='true') $cond .= " and t.value=1 "; + if($onlytrue=='true') $cond .= ' and ((t.value=1) OR (('.time().' - lastchange)<'.TRIGGER_BLINK_PERIOD.')) '; $result = DBselect("select distinct t.triggerid,t.status,t.description,t.expression,t.priority,". " t.lastchange,t.comments,t.url,t.value,h.host from triggers t,hosts h,items i,functions f". @@ -337,7 +337,7 @@ include_once "include/page_header.php"; "</FONT>"); } - if((time(NULL)-$row["lastchange"])<300) + if((time(NULL)-$row["lastchange"])<TRIGGER_BLINK_PERIOD) $blink = array(1=>"<blink>", 2=>"</blink>"); else $blink = array(1=>"", 2=>""); |
