diff options
| author | artem <artem@97f52cf1-0a1b-0410-bd0e-c28be96e8082> | 2008-07-23 09:37:47 +0000 |
|---|---|---|
| committer | artem <artem@97f52cf1-0a1b-0410-bd0e-c28be96e8082> | 2008-07-23 09:37:47 +0000 |
| commit | 5c3768ceaa3080321c3bf6481640fcdd380d0025 (patch) | |
| tree | 172b94421c008b166a1106c5c42f983c2b8fe5b3 /frontends/php/queue.php | |
| parent | 6db9d7bcf88b79ab279dd2b5dc929fabb1a23f1f (diff) | |
| download | zabbix-5c3768ceaa3080321c3bf6481640fcdd380d0025.tar.gz zabbix-5c3768ceaa3080321c3bf6481640fcdd380d0025.tar.xz zabbix-5c3768ceaa3080321c3bf6481640fcdd380d0025.zip | |
- [DEV-192] added filter to Status of triggers (Artem)
- [DEV-191] monitoring screens inline update preparation (Artem)
- [DEV-192] added severity filter in status of triggers (Artem)
- [DEV-137] sql fixes for oracle (Artem)
- [ZBX-396] fixed error maps message (Artem)
- [ZBX-394] fixed showing hosts without group in status of triggers (Artem)
- [DEV-137] small fixes (Artem)
git-svn-id: svn://svn.zabbix.com/trunk@5841 97f52cf1-0a1b-0410-bd0e-c28be96e8082
Diffstat (limited to 'frontends/php/queue.php')
| -rw-r--r-- | frontends/php/queue.php | 32 |
1 files changed, 12 insertions, 20 deletions
diff --git a/frontends/php/queue.php b/frontends/php/queue.php index 8ee50f35..0684a2fc 100644 --- a/frontends/php/queue.php +++ b/frontends/php/queue.php @@ -39,7 +39,7 @@ include_once "include/page_header.php"; check_fields($fields); - $available_hosts = get_accessible_hosts_by_user($USER_DETAILS,PERM_READ_ONLY); + $available_hosts = get_accessible_hosts_by_user($USER_DETAILS,PERM_READ_ONLY,PERM_RES_IDS_ARRAY); ?> <?php @@ -80,19 +80,17 @@ include_once "include/page_header.php"; ' or (h.status='.HOST_STATUS_MONITORED.' AND h.available='.HOST_AVAILABLE_FALSE.' AND h.disable_until<='.$now.')) '. ' AND i.hostid=h.hostid '. ' AND i.nextcheck<'.$now. - " AND i.key_ not in ('status','icmpping','icmppingsec','zabbix[log]') ". + ' AND i.key_ not in ("status","icmpping","icmppingsec","zabbix[log]") '. ' AND i.value_type not in ('.ITEM_VALUE_TYPE_LOG.') '. - ' AND h.hostid in ('.$available_hosts.')'. + ' AND '.DBcondition('h.hostid',$available_hosts). ' AND '.DBin_node('h.hostid', get_current_nodeid()). ' order by i.nextcheck,h.host,i.description,i.key_'); $table = new CTableInfo(S_THE_QUEUE_IS_EMPTY); - if($_REQUEST["show"]==0) - { + if($_REQUEST["show"]==0){ - foreach($item_types as $type) - { + foreach($item_types as $type){ $sec_5[$type]=0; $sec_10[$type]=0; $sec_30[$type]=0; @@ -101,8 +99,7 @@ include_once "include/page_header.php"; $sec_rest[$type]=0; } - while($row=DBfetch($result)) - { + while($row=DBfetch($result)){ if($now-$row["nextcheck"]<=5) $sec_5[$row["type"]]++; elseif($now-$row["nextcheck"]<=10) $sec_10[$row["type"]]++; elseif($now-$row["nextcheck"]<=30) $sec_30[$row["type"]]++; @@ -111,9 +108,9 @@ include_once "include/page_header.php"; else $sec_rest[$row["type"]]++; } + $table->setHeader(array(S_ITEMS,S_5_SECONDS,S_10_SECONDS,S_30_SECONDS,S_1_MINUTE,S_5_MINUTES,S_MORE_THAN_5_MINUTES)); - foreach($item_types as $type) - { + foreach($item_types as $type){ $elements=array( item_type2str($type), new CCol($sec_5[$type],($sec_5[$type])?"unknown_trigger":"normal"), @@ -127,16 +124,14 @@ include_once "include/page_header.php"; $table->addRow($elements); } } - else - { + else{ $table->SetHeader(array( S_NEXT_CHECK, is_show_subnodes() ? S_NODE : null, S_HOST, S_DESCRIPTION )); - while($row=DBfetch($result)) - { + while($row=DBfetch($result)){ $table->AddRow(array( date("m.d.Y H:i:s", $row["nextcheck"]), @@ -148,14 +143,11 @@ include_once "include/page_header.php"; } $table->Show(); -?> -<?php - if($_REQUEST["show"]!=0) - { + + if($_REQUEST["show"]!=0){ show_table_header(S_TOTAL.": ".$table->GetNumRows()); } ?> - <?php include_once "include/page_footer.php"; |
