From a8b6309aaaa830cc71d58144287a232774d4f2b4 Mon Sep 17 00:00:00 2001 From: hickert Date: Fri, 3 Nov 2006 08:12:46 +0000 Subject: [PATCH] Updated divlist icons git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@5003 594d385d-05f5-0310-b6e9-bd551577e9d8 --- contrib/gosa.conf | 1 + include/class_plugin.inc | 4 +--- plugins/admin/users/class_divListUsers.inc | 28 ++++++++++++++-------- 3 files changed, 20 insertions(+), 13 deletions(-) diff --git a/contrib/gosa.conf b/contrib/gosa.conf index d182696ee..f51846482 100644 --- a/contrib/gosa.conf +++ b/contrib/gosa.conf @@ -255,6 +255,7 @@ displayerros="{errorlvl}"> - "; - $_SESSION['errors'] .= "ACL BASE: ".$this->acl_base.""; - $_SESSION['errors'] .= "ACL CAT: ".$this->acl_category.""; + gosa_log("ACL ".get_class($this)." - ".$this->acl_category." - ".$this->acl_base); /* This one is empty currently. Fabian - please fill in the docu code */ $_SESSION['current_class_for_help'] = get_class($this); diff --git a/plugins/admin/users/class_divListUsers.inc b/plugins/admin/users/class_divListUsers.inc index e06517ca3..31d5a5abf 100644 --- a/plugins/admin/users/class_divListUsers.inc +++ b/plugins/admin/users/class_divListUsers.inc @@ -104,7 +104,8 @@ class divListUsers extends MultiSelectWindow } /* Get copy & paste icon */ - if(preg_match("/w/",$ui->get_permissions($this->selectedBase,"users/user")) && $this->parent->CopyPasteHandler){ + $acl = $ui->get_permissions($this->selectedBase,"users/user"); + if(preg_match("/(c.*w|w.*c)/",$acl) && $this->parent->CopyPasteHandler){ $Copy_Paste = $this->parent->CopyPasteHandler->generatePasteIcon(); }else{ $Copy_Paste =""; @@ -121,19 +122,22 @@ class divListUsers extends MultiSelectWindow "  ". " - "; - $listhead .= $this->get_snapshot_header($this->selectedBase); - $acls = $ui->get_permissions($this->selectedBase,"users/user"); - if(preg_match("/c/",$acls)) { + + if(preg_match("/(c.*w|w.*c)/",$acl)){ + $listhead .= $this->get_snapshot_header($this->selectedBase); + } + + if(preg_match("/c/",$acl)) { $listhead .= "  "; $listhead .= "  "; -# $listhead .= " - "; } - + + $listhead .= $Copy_Paste; + $listhead .= - $Copy_Paste. _("Base")." ". "  ". @@ -237,8 +241,10 @@ class divListUsers extends MultiSelectWindow /* Create action icons */ $action= ""; - /* Add copy & cut icons */ - if($this->parent->CopyPasteHandler && preg_match("/w/",$ui->get_category_permissions($val['dn'],"users"))) { + /* Add copy & cut icons */ + + $acl = $ui->get_permissions($val['dn'],"users/user"); + if(preg_match("/(c.*w|w.*c)/",$acl) && $this->parent->CopyPasteHandler){ $action .= " "; $action.= "GetSnapShotActions($val['dn']); + if(preg_match("/(c.*w|w.*c)/",$acl)){ + $action.= $this->GetSnapShotActions($val['dn']); + } /* Add remove icon, if we are allowed to remove the current user */ if(preg_match("/d/",$ui->get_permissions($val['dn'],"users/user"))) { -- 2.30.2