From: hickert Date: Fri, 16 May 2008 14:19:52 +0000 (+0000) Subject: Enabled move X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=2023afefe1399aab013f52c14d1425432a6040b1;p=gosa.git Enabled move git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@10937 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-core/include/class_plugin.inc b/gosa-core/include/class_plugin.inc index 3b05e2563..440c1e801 100644 --- a/gosa-core/include/class_plugin.inc +++ b/gosa-core/include/class_plugin.inc @@ -900,6 +900,7 @@ class plugin $ldap = $this->config->get_ldap_link(); if (!$ldap->rename_dn($src_dn,$dst_dn)){ msg_dialog::display(_("LDAP error"), msgPool::ldaperror($ldap->get_error(), $src_dn, "", get_class())); + return(FALSE); } /* Get list of groups within this tree, @@ -984,8 +985,7 @@ class plugin $ui->reset_acl_cache(); } - echo sprintf("# %s --- %.6f
",__LINE__,(microtime(1) - $start)); - return(1); + return(TRUE); } @@ -1003,7 +1003,7 @@ class plugin Currently still deactivated. !! */ - if(FALSE){ + if(TRUE){ return($this->rename($src_dn, $dst_dn)); } diff --git a/gosa-core/plugins/admin/departments/tabs_department.inc b/gosa-core/plugins/admin/departments/tabs_department.inc index 4f29396fc..7e9b45c3a 100644 --- a/gosa-core/plugins/admin/departments/tabs_department.inc +++ b/gosa-core/plugins/admin/departments/tabs_department.inc @@ -46,6 +46,7 @@ class deptabs extends tabs */ function am_i_moved() { + return(FALSE); if($this->moved) return(FALSE); $baseobject= &$this->by_object['department']; $ou = preg_replace('/,/', '\,', $baseobject->ou); @@ -90,6 +91,12 @@ class deptabs extends tabs $baseobject= &$this->by_object['department']; $ou = preg_replace('/,/', '\,', $baseobject->ou); $new_dn = @LDAP::convert('ou='.$ou.','.$baseobject->base); + + /* Move group? */ + if ($this->dn != $new_dn && $this->dn != "new"){ + $baseobject->move($this->dn,$new_dn); + } + $this->dn= $new_dn; $baseobject->dn= $this->dn; if (!$ignore_account){