From: hickert Date: Wed, 23 Dec 2009 15:03:04 +0000 (+0000) Subject: Updated acl management X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=4a3d0cdc5669a4cebb8683a09634f6fabeccf304;p=gosa.git Updated acl management -We are now able to edit things. git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@14943 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-core/plugins/admin/acl/class_aclManagement.inc b/gosa-core/plugins/admin/acl/class_aclManagement.inc index ece0a84f8..e0a508622 100644 --- a/gosa-core/plugins/admin/acl/class_aclManagement.inc +++ b/gosa-core/plugins/admin/acl/class_aclManagement.inc @@ -27,8 +27,8 @@ class aclManagement extends management var $plIcon = "plugins/acl/images/plugin.png"; // Tab definition - protected $tabClass = "acltab"; - protected $tabType = "ACLTABS"; + protected $tabClass = "aclroletab"; + protected $tabType = "ACLROLETABS"; protected $aclCategory = "acl"; protected $aclPlugin = "acl"; protected $objectName = "acl"; @@ -39,7 +39,7 @@ class aclManagement extends management $this->ui = $ui; $this->storagePoints = array(get_ou("aclRoleRDN")); // ACLs are attached to department containers - + // Build filter # if (session::global_is_set(get_class($this)."_filter")){ # $filter= session::global_get(get_class($this)."_filter"); @@ -63,8 +63,36 @@ class aclManagement extends management } parent::__construct($config, $ui, "acl", $headpage); + } + + function editEntry($action="",$target=array(),$all=array(), $altTabClass ="", $altTabType = "", $altAclCategory="") + { + $this->skipFooter = TRUE; + if(count($target) == 1){ + + // Set dummy tab object... + $this->config->data['TABS'][$this->tabType] = NULL; + $this->dn = array_pop($target); + $headpage = $this->getHeadpage(); + if($headpage->getType($this->dn) == "gosaRole"){ + $altTabClass = "aclroletab"; + }else{ + $altTabClass = "acltab"; + } + management::editEntry($action,array($this->dn),$all,$altTabClass,$altTabType,$altAclCategory); + } + } + + + function detectPostActions() + { + $action= management::detectPostActions(); + if(isset($_POST['edit_acl'])) $action['action'] = "edit_acl"; + if(isset($_POST['edit_role'])) $action['action'] = "edit_role"; + return($action); } + // A filter which allows to open a department by clicking on the departments name. static function filterLabel($row,$dn,$ou= array(),$pid=0,$base="") @@ -78,7 +106,7 @@ class aclManagement extends management } $dn= LDAP::fix(func_get_arg(1)); - return("$ou"); + return("$ou"); }