diff options
| author | hugetoad <hugetoad@97f52cf1-0a1b-0410-bd0e-c28be96e8082> | 2005-06-04 18:46:41 +0000 |
|---|---|---|
| committer | hugetoad <hugetoad@97f52cf1-0a1b-0410-bd0e-c28be96e8082> | 2005-06-04 18:46:41 +0000 |
| commit | 804a1b0eb7096d491f997fcafc4c545d9498618f (patch) | |
| tree | ce471010ab8e105c3ba4ec55e366c949bef1f1fe /frontends/php/include/escalations.inc.php | |
| parent | 546e672bbc33aae643ff0ed08275db89da9bde31 (diff) | |
Minor changes.
git-svn-id: svn://svn.zabbix.com/trunk@1816 97f52cf1-0a1b-0410-bd0e-c28be96e8082
Diffstat (limited to 'frontends/php/include/escalations.inc.php')
| -rw-r--r-- | frontends/php/include/escalations.inc.php | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/frontends/php/include/escalations.inc.php b/frontends/php/include/escalations.inc.php index 7f0576b8..3879d825 100644 --- a/frontends/php/include/escalations.inc.php +++ b/frontends/php/include/escalations.inc.php @@ -122,4 +122,39 @@ return $result; } + + # Update escalation rule definition + + function update_escalation_rule($escalationruleid,$level,$period,$delay,$actiontype) + { + if(!check_right("Configuration of Zabbix","U",0)) + { + error("Insufficient permissions"); + return 0; + } + + $sql="update escalation_rules set level=$level,period='$period',delay=$delay,actiontype=$actiontype where escalationruleid=$escalationruleid"; + $result=DBexecute($sql); + return $result; + } + + # Delete escalation rule definition + + function delete_escalation_rule($escalationruleid) + { + if(!check_right("Configuration of Zabbix","U",0)) + { + error("Insufficient permissions"); + return 0; + } + + $sql="delete from escalation_rules where escalationruleid=$escalationruleid"; + $result=DBexecute($sql); + if(!$result) + { + return $result; + } + + return $result; + } ?> |
