summaryrefslogtreecommitdiff
path: root/framework
diff options
context:
space:
mode:
authorxue <>2006-12-01 12:37:06 +0000
committerxue <>2006-12-01 12:37:06 +0000
commit4aed8371a7ddf4ac9e4eec4ae8ed3ebe039ba976 (patch)
tree202ecf03d62d185abacca392aa7d1112e5969816 /framework
parente4028427f97378efd18b63f8aa102ee07cae29fe (diff)
fixed current page index.
Diffstat (limited to 'framework')
-rw-r--r--framework/Web/UI/WebControls/TDataBoundControl.php3
1 files changed, 3 insertions, 0 deletions
diff --git a/framework/Web/UI/WebControls/TDataBoundControl.php b/framework/Web/UI/WebControls/TDataBoundControl.php
index 79175288..6e1d1003 100644
--- a/framework/Web/UI/WebControls/TDataBoundControl.php
+++ b/framework/Web/UI/WebControls/TDataBoundControl.php
@@ -337,7 +337,10 @@ abstract class TDataBoundControl extends TWebControl
$ds->setDataSource($data);
$this->setViewState('PageCount',$ds->getPageCount());
if($ds->getCurrentPageIndex()>=$ds->getPageCount())
+ {
$ds->setCurrentPageIndex($ds->getPageCount()-1);
+ $this->setCurrentPageIndex($ds->getCurrentPageIndex());
+ }
$this->performDataBinding($ds);
}
else