From 24a7926aa243bb15bc7f83579ea923c0a133eb03 Mon Sep 17 00:00:00 2001 From: hickert Date: Thu, 18 Sep 2008 12:12:19 +0000 Subject: [PATCH] Updated systemlisting -Do not display create FAI button, if ACLs ware missing. -Hide 'autonet' button. ACLs. git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@12515 594d385d-05f5-0310-b6e9-bd551577e9d8 --- gosa-plugins/systems/admin/systems/class_divListSystem.inc | 5 ++++- gosa-plugins/systems/admin/systems/class_termDNS.inc | 2 ++ gosa-plugins/systems/admin/systems/network.tpl | 3 +++ 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/gosa-plugins/systems/admin/systems/class_divListSystem.inc b/gosa-plugins/systems/admin/systems/class_divListSystem.inc index 0251feb55..732f8f6b1 100644 --- a/gosa-plugins/systems/admin/systems/class_divListSystem.inc +++ b/gosa-plugins/systems/admin/systems/class_divListSystem.inc @@ -342,7 +342,10 @@ class divListSystem extends MultiSelectWindow $action2 = $empty; } - if(in_array("gotoWorkstation",$val['objectClass'])){ + /* Add create FAI CD icon + */ + $acl_cd = preg_match("/w/",$ui->get_permissions($val['dn'],"workstation/workgeneric","createFAICD")); + if(in_array("gotoWorkstation",$val['objectClass']) && $acl_cd){ $action2= " ".$action2; }else{ diff --git a/gosa-plugins/systems/admin/systems/class_termDNS.inc b/gosa-plugins/systems/admin/systems/class_termDNS.inc index 7d5ffc58e..58d9a23a2 100644 --- a/gosa-plugins/systems/admin/systems/class_termDNS.inc +++ b/gosa-plugins/systems/admin/systems/class_termDNS.inc @@ -454,6 +454,8 @@ class termDNS extends plugin $smarty->assign("changeStateForRecords",$changeStateForRecords); $smarty->assign("staticAddress","*"); + $smarty->assign("autonetACL",$this->acl_is_writeable("macAddress").$this->acl_is_writeable("ipHostNumber")); + $display.= $smarty->fetch(get_template_path('network.tpl', TRUE)); } diff --git a/gosa-plugins/systems/admin/systems/network.tpl b/gosa-plugins/systems/admin/systems/network.tpl index e93a3e088..6401258e4 100644 --- a/gosa-plugins/systems/admin/systems/network.tpl +++ b/gosa-plugins/systems/admin/systems/network.tpl @@ -40,7 +40,10 @@ {render acl=$macAddressACL} {/render} + +{render acl=$autonetACL} +{/render} {if $dhcpEnabled} -- 2.30.2