From a3791b96142d4db65d975225b0f779bcf49ba0a8 Mon Sep 17 00:00:00 2001 From: cajus Date: Mon, 16 Jan 2006 13:15:09 +0000 Subject: [PATCH] Speeding up profile display git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@2487 594d385d-05f5-0310-b6e9-bd551577e9d8 --- plugins/admin/fai/class_faiProfile.inc | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/plugins/admin/fai/class_faiProfile.inc b/plugins/admin/fai/class_faiProfile.inc index 2150c692b..5cb6600f9 100644 --- a/plugins/admin/fai/class_faiProfile.inc +++ b/plugins/admin/fai/class_faiProfile.inc @@ -51,10 +51,17 @@ class faiProfile extends plugin } $categories = array("FAIscript","FAItemplate","FAIhook","FAIvariable","FAIpartitionTAble","FAIpackage"); + + /* Build filter */ + $filter= ""; + foreach ($categories as $cat){ + $filter.= "(objectClass=$cat)"; + } + $sort = array(); $base = $_SESSION['faifilter']['base']; $ldap->cd($base); - $ldap->search("(objectClass=*)",array("*")); + $ldap->search("(|$filter)",array("*")); while($attrs = $ldap->fetch()){ foreach($categories as $cat){ if(in_array($cat,$attrs['objectClass'])){ -- 2.30.2