diff options
author | xue <> | 2006-02-06 04:55:48 +0000 |
---|---|---|
committer | xue <> | 2006-02-06 04:55:48 +0000 |
commit | b2ff418c4f38ee2799bfa6c91618d0e5be666d0e (patch) | |
tree | 329b9218b6d9a79d2becc830a9c0d77e1a97b9d2 /framework/Web/UI | |
parent | a4f9d4234a6810c2ec8a4e53f2d903172daa0759 (diff) |
Fixed a bug in computing page numbers.
Diffstat (limited to 'framework/Web/UI')
-rw-r--r-- | framework/Web/UI/WebControls/TDataGrid.php | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/framework/Web/UI/WebControls/TDataGrid.php b/framework/Web/UI/WebControls/TDataGrid.php index 753ec351..b8151d97 100644 --- a/framework/Web/UI/WebControls/TDataGrid.php +++ b/framework/Web/UI/WebControls/TDataGrid.php @@ -1060,8 +1060,7 @@ class TDataGrid extends TBaseDataList implements INamingContainer $endPageIndex=$buttonCount;
if($pageIndex>$endPageIndex)
{
- //$startPageIndex=((int)($pageIndex/$maxButtonCount))*$maxButtonCount+1;
- $startPageIndex=$pageIndex;
+ $startPageIndex=((int)(($pageIndex-1)/$maxButtonCount))*$maxButtonCount+1;
if(($endPageIndex=$startPageIndex+$maxButtonCount-1)>$pageCount)
$endPageIndex=$pageCount;
if($endPageIndex-$startPageIndex+1<$maxButtonCount)
|