Code

Fixed copy & Paste dn
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 8 Nov 2006 11:26:14 +0000 (11:26 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 8 Nov 2006 11:26:14 +0000 (11:26 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@5042 594d385d-05f5-0310-b6e9-bd551577e9d8

plugins/admin/groups/class_groupManagement.inc

index 7158c1090fa0f3831170097f221858dedcda69f6..d3af7a032014ba94f3d0f401d765d7c1692e3c49 100644 (file)
@@ -171,7 +171,7 @@ class groupManagement extends plugin
 
         /* Save user data to ldap */
         $this->grouptab->save();
-        gosa_log ("Group object'".$this->dn."' has been saved");
+        gosa_log ("Group object '".$this->dn."' has been saved");
 
         if (!isset($_POST['edit_apply'])){
           /* Group has been saved successfully, remove lock from LDAP. */
@@ -507,7 +507,7 @@ class groupManagement extends plugin
      */
     if($s_action == "copy"){
 
-      $dn     = $this->grouplist[trim($s_entry)]['dn'];
+      $dn  = $this->grouplist[trim($s_entry)]['dn'];
       $acl = $this->ui->get_permissions($dn,"groups/group");
       if(preg_match("/(c.*w|w.*c)/",$acl)){
 
@@ -515,7 +515,7 @@ class groupManagement extends plugin
         $obj    = new grouptabs($this->config,$this->config->data['TABS']['GROUPTABS'], $dn);
         $obj->set_acl_base($dn);
         $objNew = new grouptabs($this->config,$this->config->data['TABS']['GROUPTABS'], "new");
-        $obj->set_acl_base($dn);
+        $objNew->set_acl_base($dn);
 
         $this->CopyPasteHandler->Copy($obj,$objNew);
       }else{
@@ -527,16 +527,14 @@ class groupManagement extends plugin
     /* Copy current object to CopyHandler
      */
     if($s_action == "cut"){
+      
+      $dn = $this->grouplist[trim($s_entry)]['dn'];
       $acl = $this->ui->get_permissions($dn,"groups/group");
       if(preg_match("/(c.*w|w.*c)/",$acl)){
 
         $this->CopyPasteHandler->Clear();
-        $dn = $this->grouplist[trim($s_entry)]['dn'];
-        $acl= get_permissions ($dn, $this->ui->subtreeACL);
-
         $obj= new grouptabs($this->config,$this->config->data['TABS']['GROUPTABS'], $dn);
         $obj->set_acl_base($dn);
-
         $this->CopyPasteHandler->Cut($obj);
       }else{
         print_red("You are not allowed to cut this entry.");