--- a/common/selectors.py Tue Feb 10 18:12:10 2009 +0100
+++ b/common/selectors.py Tue Feb 10 18:12:43 2009 +0100
@@ -163,7 +163,11 @@
"""
page_size = kwargs.get('page_size')
if page_size is None:
- page_size = req.property_value('navigation.page-size')
+ page_size = req.form.get('page_size')
+ if page_size is None:
+ page_size = req.property_value('navigation.page-size')
+ else:
+ page_size = int(page_size)
if rset is None or len(rset) <= page_size:
return 0
return 1
--- a/web/component.py Tue Feb 10 18:12:10 2009 +0100
+++ b/web/component.py Tue Feb 10 18:12:43 2009 +0100
@@ -83,6 +83,8 @@
instance = super(NavigationComponent, cls).selected(req, rset, row, col, **kwargs)
if page_size is not None:
instance.page_size = page_size
+ elif 'page_size' in req.form:
+ instance.page_size = int(req.form['page_size'])
return instance
def __init__(self, req, rset):