summaryrefslogtreecommitdiff
path: root/framework/Data
diff options
context:
space:
mode:
authorxue <>2007-06-15 17:25:22 +0000
committerxue <>2007-06-15 17:25:22 +0000
commitc50cc0ec1bcfefd2b28e5db0a677df6d06511984 (patch)
tree4e5fee308d73e701ce75b48b66e68c1e58ebbcfa /framework/Data
parent9df523b4eeb54d97d2040c00599b393df4f88a3e (diff)
Fixed #652.
Diffstat (limited to 'framework/Data')
-rw-r--r--framework/Data/ActiveRecord/Scaffold/TScaffoldListView.php6
1 files changed, 4 insertions, 2 deletions
diff --git a/framework/Data/ActiveRecord/Scaffold/TScaffoldListView.php b/framework/Data/ActiveRecord/Scaffold/TScaffoldListView.php
index 851bf903..edaeadd9 100644
--- a/framework/Data/ActiveRecord/Scaffold/TScaffoldListView.php
+++ b/framework/Data/ActiveRecord/Scaffold/TScaffoldListView.php
@@ -110,9 +110,11 @@ class TScaffoldListView extends TScaffoldBase
$limit = $total - $offset;
$criteria = new TActiveRecordCriteria($this->getSearchCondition(), $this->getSearchParameters());
if($limit > 0)
+ {
$criteria->setLimit($limit);
- if($offset <= $total)
- $criteria->setOffset($offset);
+ if($offset <= $total)
+ $criteria->setOffset($offset);
+ }
$order = explode(' ',$this->_sort->getSelectedValue(), 2);
if(is_array($order) && count($order) === 2)
$criteria->OrdersBy[$order[0]] = $order[1];