Code

Removed debug output
authorcajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8>
Mon, 21 Aug 2006 12:10:18 +0000 (12:10 +0000)
committercajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8>
Mon, 21 Aug 2006 12:10:18 +0000 (12:10 +0000)
Made department filter effective

git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@4494 594d385d-05f5-0310-b6e9-bd551577e9d8

plugins/admin/users/class_divListUsers.inc

index 30423e60c0714668b27ce15ab31022b21bebe0fa..d239375b8c7c9ed2a457f5a2c0ff10b298a6dd1e 100644 (file)
@@ -85,16 +85,14 @@ class divListUsers extends MultiSelectWindow
     $deps= get_list("(&(|(ou=*)(description=*))(objectClass=gosaDepartment))", $this->module, $base,
                     array("ou", "description"), GL_SIZELIMIT | GL_SUBSEARCH);
 
-$ui= get_userinfo();
-$t= $ui->get_module_departments("users");
-print_a($t);
+    /* Load possible departments */
+    $ui= get_userinfo();
+    $tdeps= $ui->get_module_departments("users");
 
     $ids = $this->config->idepartments;
  
-print_a($ids);
-
     foreach($deps as $dep){
-      if(isset($ids[$dep['dn']])){
+      if(isset($ids[$dep['dn']]) && in_array_ics($dep['dn'], $tdeps)){
 
         $value = $ids[$dep['dn']]; 
         if ($this->selectedBase == $dep['dn']){