From ef4d76165d7365abcc8bfc816ef4f1e8a182ed26 Mon Sep 17 00:00:00 2001 From: hugetoad Date: Sun, 7 Mar 2004 08:07:46 +0000 Subject: - added button "add items from template" (Alexei) git-svn-id: svn://svn.zabbix.com/trunk@1290 97f52cf1-0a1b-0410-bd0e-c28be96e8082 --- frontends/php/hosts.php | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'frontends/php/hosts.php') diff --git a/frontends/php/hosts.php b/frontends/php/hosts.php index 0d92566c..d26a9d00 100644 --- a/frontends/php/hosts.php +++ b/frontends/php/hosts.php @@ -44,6 +44,12 @@ show_messages($result,"Host added","Cannot add host"); unset($HTTP_GET_VARS["hostid"]); } + if($HTTP_GET_VARS["register"]=="add items from template") + { + $result=add_using_host_template($HTTP_GET_VARS["hostid"],$HTTP_GET_VARS["host_templateid"]); + show_messages($result,"Items added","Cannot add items"); + unset($HTTP_GET_VARS["hostid"]); + } if($HTTP_GET_VARS["register"]=="update") { $result=@update_host($HTTP_GET_VARS["hostid"],$HTTP_GET_VARS["host"],$HTTP_GET_VARS["port"],$HTTP_GET_VARS["status"],$HTTP_GET_VARS["useip"],$HTTP_GET_VARS["ip"],$HTTP_GET_VARS["newgroup"],$HTTP_GET_VARS["groups"]); @@ -432,6 +438,7 @@ echo ""; if(isset($HTTP_GET_VARS["hostid"])) { + echo ""; echo ""; echo ""; } -- cgit