From: hickert Date: Wed, 13 Feb 2008 07:26:47 +0000 (+0000) Subject: Fixed menu creation. X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=93e658018ece0a31b61aa23cf38758ac2cb488cc;p=gosa.git Fixed menu creation. -Plugin acls wasn't checked correctly. Now we also see the systems management plugin if we only have terminal acls set. git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@8882 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-core/include/class_pluglist.inc b/gosa-core/include/class_pluglist.inc index 87dcd7693..8f24af339 100644 --- a/gosa-core/include/class_pluglist.inc +++ b/gosa-core/include/class_pluglist.inc @@ -79,26 +79,21 @@ class pluglist { function check_access($aclname) { - $deps= $this->ui->get_module_departments($aclname); - $acls_to_check = array(); if(preg_match("/,/",$aclname)){ $acls_to_check = split(",",$aclname); }else{ $acls_to_check = array($aclname); } - - if(preg_match("/\//",$aclname)){ + + foreach($acls_to_check as $acl_to_check){ + $deps = $this->ui->get_module_departments($acl_to_check); foreach($deps as $dep){ - foreach($acls_to_check as $acl_to_check){ + if(preg_match("/\//",$acl_to_check)){ if($this->ui->get_permissions($dep,$acl_to_check) != ""){ return(TRUE); } - } - } - }else{ - foreach($deps as $dep){ - foreach($acls_to_check as $acl_to_check){ + }else{ if($this->ui->get_category_permissions($dep,$acl_to_check) != ""){ return(TRUE); }