summaryrefslogtreecommitdiffstats
path: root/frontends/php/include/classes
diff options
context:
space:
mode:
authorosmiy <osmiy@97f52cf1-0a1b-0410-bd0e-c28be96e8082>2007-02-07 09:27:20 +0000
committerosmiy <osmiy@97f52cf1-0a1b-0410-bd0e-c28be96e8082>2007-02-07 09:27:20 +0000
commit2d76733fbfa2cdb0935210e524f373c18ef47ee9 (patch)
treed40cf2e113983d93e2c11af9bb5ad45a54235587 /frontends/php/include/classes
parent4ceb822c9fdd9cb84040e4d104942c6dc565504e (diff)
downloadzabbix-2d76733fbfa2cdb0935210e524f373c18ef47ee9.tar.gz
zabbix-2d76733fbfa2cdb0935210e524f373c18ef47ee9.tar.xz
zabbix-2d76733fbfa2cdb0935210e524f373c18ef47ee9.zip
- fixed graphs in Oracle system (Eugene)
- fixed trigger expressions with ':' (Eugene) - fixed 'Server info' screen componets (Eugene) git-svn-id: svn://svn.zabbix.com/trunk@3804 97f52cf1-0a1b-0410-bd0e-c28be96e8082
Diffstat (limited to 'frontends/php/include/classes')
-rw-r--r--frontends/php/include/classes/cserverinfo.mod.php4
-rw-r--r--frontends/php/include/classes/graph.inc.php13
2 files changed, 9 insertions, 8 deletions
diff --git a/frontends/php/include/classes/cserverinfo.mod.php b/frontends/php/include/classes/cserverinfo.mod.php
index 3ebe1765..d0da6951 100644
--- a/frontends/php/include/classes/cserverinfo.mod.php
+++ b/frontends/php/include/classes/cserverinfo.mod.php
@@ -48,8 +48,8 @@
$this->AddRow(S_NUMBER_OF_USERS_SHORT.": ".$status["users_count"]."(".$status["users_online"].")");
$this->AddRow(new CCol(array("Logged in as ", new CLink($USER_DETAILS["alias"],"profile.php","action"))));
$this->AddRow(new CCol(array(new CLink("ZABBIX server","http://www.zabbix.com","action")," is ",$server)),"status");
- $this->AddRow(S_VALUES_STORED.": ".$status["history_count"]);
- $this->AddRow(S_TRENDS_STORED.": ".$status["trends_count"]);
+ //$this->AddRow(S_VALUES_STORED.": ".$status["history_count"]);
+ //$this->AddRow(S_TRENDS_STORED.": ".$status["trends_count"]);
$this->AddRow(new CCol(array(S_NUMBER_OF_HOSTS_SHORT.": ".$status["hosts_count"]."(",
new CSpan($status["hosts_count_monitored"],"off"),"/",
new CSpan($status["hosts_count_not_monitored"],"on"),"/",
diff --git a/frontends/php/include/classes/graph.inc.php b/frontends/php/include/classes/graph.inc.php
index 9daa0f67..88a54a7f 100644
--- a/frontends/php/include/classes/graph.inc.php
+++ b/frontends/php/include/classes/graph.inc.php
@@ -985,32 +985,33 @@
$to_time = $this->to_time;
}
+ $calc_field = 'round('.$x.'*(mod(clock+'.$z.','.$p.'))/('.$p.'),0)'; /* required for 'group by' support of Oracle */
$sql_arr = array();
if(($this->period / $this->sizeX) <= (ZBX_MAX_TREND_DIFF / ZBX_GRAPH_MAX_SKIP_CELL))
{
array_push($sql_arr,
- 'select itemid,round('.$x.'*(mod(clock+'.$z.','.$p.'))/('.$p.'),0) as i,'.
+ 'select itemid,'.$calc_field.' as i,'.
' count(*) as count,avg(value) as avg,min(value) as min,'.
' max(value) as max,max(clock) as clock'.
' from history where itemid='.$this->items[$i]['itemid'].' and clock>='.$from_time.
- ' and clock<='.$to_time.' group by itemid, i' //' round('.$x.'*(mod(clock+'.$z.','.$p.'))/('.$p.'),0)',
+ ' and clock<='.$to_time.' group by itemid,'.$calc_field
,
- 'select itemid,round('.$x.'*(mod(clock+'.$z.','.$p.'))/('.$p.'),0) as i,'.
+ 'select itemid,'.$calc_field.' as i,'.
' count(*) as count,avg(value) as avg,min(value) as min,'.
' max(value) as max,max(clock) as clock'.
' from history_uint where itemid='.$this->items[$i]['itemid'].' and clock>='.$from_time.
- ' and clock<='.$to_time.' group by itemid, i' //' round('.$x.'*(mod(clock+'.$z.','.$p.'))/('.$p.'),0)'
+ ' and clock<='.$to_time.' group by itemid,'.$calc_field
);
}
else
{
array_push($sql_arr,
- 'select itemid,round('.$x.'*(mod(clock+'.$z.','.$p.'))/('.$p.'),0) as i,'.
+ 'select itemid,'.$calc_field.' as i,'.
' sum(num) as count,avg(value_avg) as avg,min(value_min) as min,'.
' max(value_max) as max,max(clock) as clock'.
' from trends where itemid='.$this->items[$i]['itemid'].' and clock>='.$from_time.
- ' and clock<='.$to_time.' group by itemid, i' //' round('.$x.'*(mod(clock+'.$z.','.$p.'))/('.$p.'),0)'
+ ' and clock<='.$to_time.' group by itemid,'.$calc_field
);
}