Use batch fetchers for search
authorRaphaël Barrois <raphael.barrois@polytechnique.org>
Mon, 22 Mar 2010 15:06:40 +0000 (16:06 +0100)
committerRaphaël Barrois <raphael.barrois@polytechnique.org>
Mon, 22 Mar 2010 15:06:40 +0000 (16:06 +0100)
Signed-off-by: Raphaël Barrois <raphael.barrois@polytechnique.org>
core
include/userset.inc.php

diff --git a/core b/core
index c291ca5..501a6db 160000 (submodule)
--- a/core
+++ b/core
@@ -1 +1 @@
-Subproject commit c291ca5486bce705cd3dfd81065cbd2d92b96da5
+Subproject commit 501a6db205b3355bd9e15de6eac20ca033835201
index 73ba6c8..a403b8a 100644 (file)
@@ -115,17 +115,9 @@ class SearchSet extends ProfileSet
         $this->conds->addChild($ufb->getUFC());
     }
 
-    public function &get(PlLimit $limit = null, $orders = array())
+    protected function &getFilterResults(PlFilter &$pf, PlLimit $limit)
     {
-        $orders = array_merge($orders, $this->orders);
-
-        $uf = $this->buildFilter($this->conds, $orders);
-        if (is_null($limit)) {
-            $limit = new PlLimit(20, 0);
-        }
-        $it          = $uf->getProfiles($limit);
-        $this->count = $uf->getTotalCount();
-        return $it;
+        return $pf->getProfiles($limit, Profile::FETCH_MINIFICHES);
     }
 }