diff options
Diffstat (limited to 'frontends/php/include')
-rw-r--r-- | frontends/php/include/config.inc.php | 8 | ||||
-rw-r--r-- | frontends/php/include/items.inc.php | 3 | ||||
-rw-r--r-- | frontends/php/include/local_en.inc.php | 9 | ||||
-rw-r--r-- | frontends/php/include/screens.inc.php | 8 | ||||
-rw-r--r-- | frontends/php/include/services.inc.php | 5 |
5 files changed, 22 insertions, 11 deletions
diff --git a/frontends/php/include/config.inc.php b/frontends/php/include/config.inc.php index 0a94db27..321f0058 100644 --- a/frontends/php/include/config.inc.php +++ b/frontends/php/include/config.inc.php @@ -1957,7 +1957,7 @@ echo "</head>"; # Add Media definition - function add_media( $userid, $mediatypeid, $sendto, $severity, $active) + function add_media( $userid, $mediatypeid, $sendto, $severity, $active, $period) { $c=count($severity); $s=0; @@ -1965,13 +1965,13 @@ echo "</head>"; { $s=$s|pow(2,(int)$severity[$i]); } - $sql="insert into media (userid,mediatypeid,sendto,active,severity) values ($userid,'$mediatypeid','$sendto',$active,$s)"; + $sql="insert into media (userid,mediatypeid,sendto,active,severity,period) values ($userid,'$mediatypeid','$sendto',$active,$s,'$period')"; return DBexecute($sql); } # Update Media definition - function update_media($mediaid, $userid, $mediatypeid, $sendto, $severity, $active) + function update_media($mediaid, $userid, $mediatypeid, $sendto, $severity, $active, $period) { $c=count($severity); $s=0; @@ -1979,7 +1979,7 @@ echo "</head>"; { $s=$s|pow(2,(int)$severity[$i]); } - $sql="update media set userid=$userid, mediatypeid=$mediatypeid, sendto='$sendto', active=$active,severity=$s where mediaid=$mediaid"; + $sql="update media set userid=$userid, mediatypeid=$mediatypeid, sendto='$sendto', active=$active,severity=$s,period=`$period` where mediaid=$mediaid"; return DBexecute($sql); } diff --git a/frontends/php/include/items.inc.php b/frontends/php/include/items.inc.php index 348f38fd..796bb2b2 100644 --- a/frontends/php/include/items.inc.php +++ b/frontends/php/include/items.inc.php @@ -118,6 +118,9 @@ $snmpv3_authpassphrase=addslashes($snmpv3_authpassphrase); $snmpv3_privpassphrase=addslashes($snmpv3_privpassphrase); + $sql="update items set lastlogsize=0 where itemid=$itemid and key_<>'$key'"; + DBexecute($sql); + $sql="update items set description='$description',key_='$key',hostid=$hostid,delay=$delay,history=$history,nextcheck=0,status=$status,type=$type,snmp_community='$snmp_community',snmp_oid='$snmp_oid',value_type=$value_type,trapper_hosts='$trapper_hosts',snmp_port=$snmp_port,units='$units',multiplier=$multiplier,delta=$delta,snmpv3_securityname='$snmpv3_securityname',snmpv3_securitylevel=$snmpv3_securitylevel,snmpv3_authpassphrase='$snmpv3_authpassphrase',snmpv3_privpassphrase='$snmpv3_privpassphrase',formula='$formula',trends=$trends where itemid=$itemid"; $result=DBexecute($sql); if($result) diff --git a/frontends/php/include/local_en.inc.php b/frontends/php/include/local_en.inc.php index 5170b98c..87efa7f8 100644 --- a/frontends/php/include/local_en.inc.php +++ b/frontends/php/include/local_en.inc.php @@ -25,7 +25,7 @@ // about.php define("S_ABOUT_ZABBIX", "About ZABBIX"); - define("S_INFORMATION_ABOUT_ZABBIX", "Information about ZABBIX (v1.1alpha9)"); + define("S_INFORMATION_ABOUT_ZABBIX", "Information about ZABBIX (v1.1alpha10)"); define("S_HOMEPAGE_OF_ZABBIX", "Homepage of ZABBIX"); define("S_HOMEPAGE_OF_ZABBIX_DETAILS", "This is home page of ZABBIX."); define("S_LATEST_ZABBIX_MANUAL", "Latest ZABBIX Manual"); @@ -168,7 +168,8 @@ define("S_NO_ESCALATION_RULES_DEFINED", "No escalation rules defined"); define("S_NO_ESCALATION_DETAILS", "No escalation details"); define("S_ESCALATION_DETAILS_BIG", "ESCALATION DETAILS"); - define("S_STEP", "Step"); + define("S_LEVEL", "Level"); + define("S_DELAY_BEFORE_ACTION", "Delay before action"); define("S_IMAGES", "Images"); define("S_IMAGE", "Image"); define("S_IMAGES_BIG", "IMAGES"); @@ -192,7 +193,7 @@ define("S_COMPARE", "Compare"); // Footer - define("S_ZABBIX_VER", "ZABBIX 1.1alpha9"); + define("S_ZABBIX_VER", "ZABBIX 1.1alpha10"); define("S_COPYRIGHT_BY", "Copyright 2001-2005 by "); define("S_CONNECTED_AS", "Connected as"); define("S_SIA_ZABBIX", "SIA Zabbix"); @@ -404,6 +405,7 @@ define("S_MEDIA_DELETED", "Media deleted"); define("S_CANNOT_DELETE_MEDIA", "Cannot delete media"); define("S_SEND_TO", "Send to"); + define("S_WHEN_ACTIVE", "When active"); define("S_NO_MEDIA_DEFINED", "No media defined"); define("S_NEW_MEDIA", "New media"); define("S_USE_IF_SEVERITY", "Use if severity"); @@ -515,6 +517,7 @@ // screenedit.php define("S_MAP", "Map"); define("S_PLAIN_TEXT", "Plain text"); + define("S_COLSPAN", "Colspan"); // screens.php define("S_CUSTOM_SCREENS", "Custom screens"); diff --git a/frontends/php/include/screens.inc.php b/frontends/php/include/screens.inc.php index 1439e45e..6f2f955c 100644 --- a/frontends/php/include/screens.inc.php +++ b/frontends/php/include/screens.inc.php @@ -55,17 +55,17 @@ return DBexecute($sql); } - function add_screen_item($resource,$screenid,$x,$y,$resourceid,$width,$height) + function add_screen_item($resource,$screenid,$x,$y,$resourceid,$width,$height,$colspan) { $sql="delete from screens_items where screenid=$screenid and x=$x and y=$y"; DBexecute($sql); - $sql="insert into screens_items (resource,screenid,x,y,resourceid,width,height) values ($resource,$screenid,$x,$y,$resourceid,$width,$height)"; + $sql="insert into screens_items (resource,screenid,x,y,resourceid,width,height,colspan) values ($resource,$screenid,$x,$y,$resourceid,$width,$height,$colspan)"; return DBexecute($sql); } - function update_screen_item($screenitemid,$resource,$resourceid,$width,$height) + function update_screen_item($screenitemid,$resource,$resourceid,$width,$height,$colspan) { - $sql="update screens_items set resource=$resource,resourceid=$resourceid,width=$width,height=$height where screenitemid=$screenitemid"; + $sql="update screens_items set resource=$resource,resourceid=$resourceid,width=$width,height=$height,colspan=$colspan where screenitemid=$screenitemid"; return DBexecute($sql); } diff --git a/frontends/php/include/services.inc.php b/frontends/php/include/services.inc.php index 23e68379..bbaabf5d 100644 --- a/frontends/php/include/services.inc.php +++ b/frontends/php/include/services.inc.php @@ -31,6 +31,11 @@ } if( isset($linktrigger)&&($linktrigger=="on") ) { + if(!isset($triggerid)) + { + error("Choose trigger first"); + return false; + } // $trigger=get_trigger_by_triggerid($triggerid); // $description=$trigger["description"]; // if( strstr($description,"%s")) |