summaryrefslogtreecommitdiffstats
path: root/frontends/php/include
diff options
context:
space:
mode:
authorhugetoad <hugetoad@97f52cf1-0a1b-0410-bd0e-c28be96e8082>2004-09-18 08:15:56 +0000
committerhugetoad <hugetoad@97f52cf1-0a1b-0410-bd0e-c28be96e8082>2004-09-18 08:15:56 +0000
commit984e8708f85679aefd3d0029383e8fefbaf647a0 (patch)
tree5c01c40c2f38bbd525942ecce7e21bcb77366787 /frontends/php/include
parent44e8cd98347176a8c79a470c5a0b7e6d236991e0 (diff)
downloadzabbix-984e8708f85679aefd3d0029383e8fefbaf647a0.tar.gz
zabbix-984e8708f85679aefd3d0029383e8fefbaf647a0.tar.xz
zabbix-984e8708f85679aefd3d0029383e8fefbaf647a0.zip
Better audit support.
git-svn-id: svn://svn.zabbix.com/trunk@1428 97f52cf1-0a1b-0410-bd0e-c28be96e8082
Diffstat (limited to 'frontends/php/include')
-rw-r--r--frontends/php/include/config.inc.php19
-rw-r--r--frontends/php/include/defines.inc.php3
2 files changed, 21 insertions, 1 deletions
diff --git a/frontends/php/include/config.inc.php b/frontends/php/include/config.inc.php
index 34c67db0..a7e551ad 100644
--- a/frontends/php/include/config.inc.php
+++ b/frontends/php/include/config.inc.php
@@ -666,6 +666,23 @@ where h.hostid=i.hostid and i.itemid=f.itemid and f.triggerid=$triggerid";
}
+ function get_graphitem_by_gitemid($gitemid)
+ {
+ global $ERROR_MSG;
+
+ $sql="select * from graphs_items where gitemid=$gitemid";
+ $result=DBselect($sql);
+ if(DBnum_rows($result) == 1)
+ {
+ return DBfetch($result);
+ }
+ else
+ {
+ $ERROR_MSG="No graph item with gitemid=[$gitemid]";
+ }
+ return $result;
+ }
+
function get_graph_by_graphid($graphid)
{
global $ERROR_MSG;
@@ -680,7 +697,7 @@ where h.hostid=i.hostid and i.itemid=f.itemid and f.triggerid=$triggerid";
{
$ERROR_MSG="No graph with graphid=[$graphid]";
}
- return $graph;
+ return $result;
}
function get_image_by_name($imagetype,$name)
diff --git a/frontends/php/include/defines.inc.php b/frontends/php/include/defines.inc.php
index 24c10940..e1a7f93d 100644
--- a/frontends/php/include/defines.inc.php
+++ b/frontends/php/include/defines.inc.php
@@ -30,6 +30,9 @@
define("AUDIT_RESOURCE_ZABBIX_CONFIG", 2);
define("AUDIT_RESOURCE_MEDIA_TYPE", 3);
define("AUDIT_RESOURCE_HOST", 4);
+ define("AUDIT_RESOURCE_ACTION", 5);
+ define("AUDIT_RESOURCE_GRAPH", 6);
+
define("HOST_STATUS_MONITORED", 0);