From 3a7e705078d642e51c36ff768c0093ebce90d7b0 Mon Sep 17 00:00:00 2001 From: hickert Date: Wed, 5 Mar 2008 10:41:03 +0000 Subject: [PATCH] Fixed fai classes -No overlapping searches anymore. git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@9345 594d385d-05f5-0310-b6e9-bd551577e9d8 --- plugins/admin/fai/class_faiHook.inc | 4 ++++ plugins/admin/fai/class_faiScript.inc | 5 +++++ plugins/admin/fai/class_faiTemplate.inc | 4 ++++ 3 files changed, 13 insertions(+) diff --git a/plugins/admin/fai/class_faiHook.inc b/plugins/admin/fai/class_faiHook.inc index c00c14dc3..dc137feb8 100644 --- a/plugins/admin/fai/class_faiHook.inc +++ b/plugins/admin/fai/class_faiHook.inc @@ -71,7 +71,11 @@ class faiHook extends plugin $ldap->cd ($this->dn); $ldap->search("(&(objectClass=FAIclass)(objectClass=".$this->subClass."))",array("dn")); + $data = array(); while($object = $ldap->fetch()){ + $data[] = $object; + } + foreach($data as $object){ /* Set status for save management */ $objects = array(); diff --git a/plugins/admin/fai/class_faiScript.inc b/plugins/admin/fai/class_faiScript.inc index c4a84f381..41a2f3e18 100644 --- a/plugins/admin/fai/class_faiScript.inc +++ b/plugins/admin/fai/class_faiScript.inc @@ -76,7 +76,12 @@ class faiScript extends plugin $ldap->cd ($this->dn); $ldap->search("(&(objectClass=FAIclass)(objectClass=".$this->subClass."))",$this->subAttributes); + $data = array(); while($object = $ldap->fetch()){ + $data[] = $object; + } + foreach($data as $object){ + /* Set status for save management */ $objects = array(); $objects['status'] = "FreshLoaded"; diff --git a/plugins/admin/fai/class_faiTemplate.inc b/plugins/admin/fai/class_faiTemplate.inc index 6a27eeca4..f70f91ae7 100644 --- a/plugins/admin/fai/class_faiTemplate.inc +++ b/plugins/admin/fai/class_faiTemplate.inc @@ -72,7 +72,11 @@ class faiTemplate extends plugin $ldap->cd ($this->dn); $ldap->search("(&(objectClass=FAIclass)(objectClass=".$this->subClass."))",array("dn")); + $data = array(); while($object = $ldap->fetch()){ + $data[] = $object; + } + foreach($data as $object){ /* Set status for save management */ $objects = array(); -- 2.30.2