From 8fb7b531cfc1b4725d9c095c1a6bd2f22a8ecd71 Mon Sep 17 00:00:00 2001 From: ajshort Date: Fri, 1 Apr 2011 15:10:27 +1100 Subject: [PATCH] MINOR: Updated MySQLDatabase::searchEngine() to use the new PaginatedList API. --- model/MySQLDatabase.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) mode change 100755 => 100644 model/MySQLDatabase.php diff --git a/model/MySQLDatabase.php b/model/MySQLDatabase.php old mode 100755 new mode 100644 index 9f5e70ca5..67d969b13 --- a/model/MySQLDatabase.php +++ b/model/MySQLDatabase.php @@ -832,8 +832,12 @@ class MySQLDatabase extends SS_Database { if(isset($objects)) $doSet = new DataObjectSet($objects); else $doSet = new DataObjectSet(); - $doSet->setPageLimits($start, $pageLength, $totalCount); - return $doSet; + $list = new PaginatedList($doSet); + $list->setPageStart($start); + $list->setPageLEngth($pageLength); + $list->setTotalItems($totalCount); + + return $list; } /**