From e266dc4055cf5e0eba56819350583e2513266cff Mon Sep 17 00:00:00 2001 From: hickert Date: Wed, 28 May 2008 08:54:05 +0000 Subject: [PATCH] Added move / create checks git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@11063 594d385d-05f5-0310-b6e9-bd551577e9d8 --- gosa-core/plugins/admin/ogroups/class_ogroup.inc | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/gosa-core/plugins/admin/ogroups/class_ogroup.inc b/gosa-core/plugins/admin/ogroups/class_ogroup.inc index f64b00ba5..34464dcdc 100644 --- a/gosa-core/plugins/admin/ogroups/class_ogroup.inc +++ b/gosa-core/plugins/admin/ogroups/class_ogroup.inc @@ -48,6 +48,8 @@ class ogroup extends plugin var $memberList= array(); var $member= array(); var $orig_dn= ""; + var $orig_cn= ""; + var $orig_base= ""; var $group_dialog= FALSE; var $view_logged = FALSE; @@ -138,6 +140,9 @@ class ogroup extends plugin } } + $this->orig_cn = $this->cn; + $this->orig_base = $this->base; + /* Load member data */ $this->reload(); } @@ -867,6 +872,14 @@ class ogroup extends plugin $message[]= _("You can combine two different object types at maximum, only!"); } + /* Check if we are allowed to create or move this object + */ + if($this->dn == "new" && !$this->acl_is_createable($this->base)){ + $message[] = msgPool::permCreate(); + }elseif($this->cn != $this->orig_cn || $this->base != $this->orig_base && !$this->acl_is_moveable($this->base)){ + $message[] = msgPool::permMove(); + } + return ($message); } -- 2.30.2