summaryrefslogtreecommitdiffstats
path: root/frontends/php/hosts.php
diff options
context:
space:
mode:
authorosmiy <osmiy@97f52cf1-0a1b-0410-bd0e-c28be96e8082>2006-01-26 16:08:54 +0000
committerosmiy <osmiy@97f52cf1-0a1b-0410-bd0e-c28be96e8082>2006-01-26 16:08:54 +0000
commit2f3c1099996bca8c050b452852d52d91cb6be3f6 (patch)
tree5798dd1aa97193482203c9ecacb7e04a17979849 /frontends/php/hosts.php
parent3d3f9639bc0524d6085d11041d70d23fbbda1c88 (diff)
downloadzabbix-2f3c1099996bca8c050b452852d52d91cb6be3f6.tar.gz
zabbix-2f3c1099996bca8c050b452852d52d91cb6be3f6.tar.xz
zabbix-2f3c1099996bca8c050b452852d52d91cb6be3f6.zip
- Frontend improvements (Eugene)
git-svn-id: svn://svn.zabbix.com/trunk@2565 97f52cf1-0a1b-0410-bd0e-c28be96e8082
Diffstat (limited to 'frontends/php/hosts.php')
-rw-r--r--frontends/php/hosts.php19
1 files changed, 10 insertions, 9 deletions
diff --git a/frontends/php/hosts.php b/frontends/php/hosts.php
index 292c28c9..48e7306f 100644
--- a/frontends/php/hosts.php
+++ b/frontends/php/hosts.php
@@ -317,13 +317,13 @@
$result=update_template_linkage($_REQUEST["hosttemplateid"],$_REQUEST["hostid"],$_REQUEST["templateid"],$items,$triggers,$graphs);
show_messages($result, S_TEMPLATE_LINKAGE_UPDATED, S_CANNOT_UPDATE_TEMPLATE_LINKAGE);
}
- if($_REQUEST["register"]=="delete linkage")
- {
- $result=delete_template_linkage($_REQUEST["hosttemplateid"]);
- show_messages($result, S_TEMPLATE_LINKAGE_DELETED, S_CANNOT_DELETE_TEMPLATE_LINKAGE);
- unset($_REQUEST["hosttemplateid"]);
- }
}
+ if($_REQUEST["config"]==2&&isset($_REQUEST["delete"])&&isset($_REQUEST["hosttemplateid"]))
+ {
+ $result=delete_template_linkage($_REQUEST["hosttemplateid"]);
+ show_messages($result, S_TEMPLATE_LINKAGE_DELETED, S_CANNOT_DELETE_TEMPLATE_LINKAGE);
+ unset($_REQUEST["hosttemplateid"]);
+ }
?>
@@ -419,7 +419,7 @@
if(isset($_REQUEST["hostid"]))
{
echo BR;
- @insert_template_form($_REQUEST["hostid"], $_REQUEST["hosttemplateid"]);
+ insert_template_form();
echo BR;
$table = new CTableInfo(S_NO_LINKAGES_DEFINED);
@@ -430,7 +430,6 @@
{
$host=get_host_by_hostid($row["hostid"]);
$template=get_host_by_hostid($row["templateid"]);
- $actions="<a href=\"hosts.php?config=2&hostid=".$row["hostid"]."&hosttemplateid=".$row["hosttemplateid"]."\">".S_CHANGE."</a>";
$table->addRow(array(
$host["host"],
@@ -438,7 +437,9 @@
get_template_permission_str($row["items"]),
get_template_permission_str($row["triggers"]),
get_template_permission_str($row["graphs"]),
- $actions
+ new CLink(S_CHANGE, "hosts.php?form=0".url_param("config").
+ "&hostid=".$row["hostid"].
+ "&hosttemplateid=".$row["hosttemplateid"])
));
}
$table->show();