From a07e09435049ea336a78091402dab09261688d6e Mon Sep 17 00:00:00 2001 From: hickert Date: Thu, 18 May 2006 10:35:46 +0000 Subject: [PATCH] Used divlist instead of ldapserach git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@3422 594d385d-05f5-0310-b6e9-bd551577e9d8 --- .../admin/groups/class_groupApplication.inc | 24 ++++--------------- 1 file changed, 5 insertions(+), 19 deletions(-) diff --git a/plugins/admin/groups/class_groupApplication.inc b/plugins/admin/groups/class_groupApplication.inc index ede18a166..c3ef74b5e 100644 --- a/plugins/admin/groups/class_groupApplication.inc +++ b/plugins/admin/groups/class_groupApplication.inc @@ -605,22 +605,11 @@ class appgroup extends plugin $div->SetHeight(300); - /* NEW LIST MANAGMENT - * We also need to search for the departments - * So we are able to navigate like in konquerer - */ - - //FIXME: Why do we not use get_list here? It's the same code all over the time... - $ldap = $this->config->get_ldap_link(); - $ldap->cd($this->curbase) ; - $ldap->ls("(objectClass=gosaDepartment)"); - $departments= array(); - $tmp = array(); - while ($value = $ldap->fetch()){ - $tmp[strtolower($value['dn']).$value['dn']]=$value; - } - ksort($tmp); - foreach($tmp as $value){ + /* get departments */ + $ui = get_userinfo(); + $departments = array(); + $res = get_list("(objectClass=gosaDepartment)",$ui->subtreeACL,$this->curbase,array("description","cn","ou"),GL_SIZELIMIT); + foreach($res as $value){ $fdn= @LDAP::fix($value['dn']); if($value["description"][0]!=".."){ $departments[$value['dn']]= convert_department_dn($fdn)." - [".$value["description"][0]."]"; @@ -629,9 +618,6 @@ class appgroup extends plugin } } - /* END NEW LIST MANAGMENT - */ - $linkopen = "%s"; $linkadd = "%s"; -- 2.30.2