From a4f9d4234a6810c2ec8a4e53f2d903172daa0759 Mon Sep 17 00:00:00 2001 From: xue <> Date: Mon, 6 Feb 2006 03:47:15 +0000 Subject: Fixed a bug about calculating the starting pager button in TDataGrid. --- framework/Web/UI/WebControls/TDataGrid.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/framework/Web/UI/WebControls/TDataGrid.php b/framework/Web/UI/WebControls/TDataGrid.php index 57d00ac8..753ec351 100644 --- a/framework/Web/UI/WebControls/TDataGrid.php +++ b/framework/Web/UI/WebControls/TDataGrid.php @@ -1060,7 +1060,8 @@ class TDataGrid extends TBaseDataList implements INamingContainer $endPageIndex=$buttonCount; if($pageIndex>$endPageIndex) { - $startPageIndex=((int)($pageIndex/$maxButtonCount))*$maxButtonCount+1; + //$startPageIndex=((int)($pageIndex/$maxButtonCount))*$maxButtonCount+1; + $startPageIndex=$pageIndex; if(($endPageIndex=$startPageIndex+$maxButtonCount-1)>$pageCount) $endPageIndex=$pageCount; if($endPageIndex-$startPageIndex+1<$maxButtonCount) -- cgit v1.2.3