[tableview,jsoncontroller] the json controller must check view.handle_pagination as well & the old table view also handles pagination internally
authorAurelien Campeas <aurelien.campeas@logilab.fr>
Tue, 25 Oct 2011 13:51:27 +0200
changeset 8016 1a1b23c37013
parent 8015 b9de628f90e6
child 8018 f01c80513274
[tableview,jsoncontroller] the json controller must check view.handle_pagination as well & the old table view also handles pagination internally
web/views/basecontrollers.py
web/views/tableview.py
--- a/web/views/basecontrollers.py	Mon Oct 24 13:52:24 2011 +0200
+++ b/web/views/basecontrollers.py	Tue Oct 25 13:51:27 2011 +0200
@@ -353,7 +353,7 @@
             if vtitle:
                 stream.write(u'<h1 class="vtitle">%s</h1>\n' % vtitle)
             paginate = True
-        if paginate:
+        if paginate and not view.handle_pagination:
             view.paginate()
         if divid == 'pageContent':
             stream.write(u'<div id="contentmain">')
--- a/web/views/tableview.py	Mon Oct 24 13:52:24 2011 +0200
+++ b/web/views/tableview.py	Tue Oct 25 13:51:27 2011 +0200
@@ -812,6 +812,7 @@
         'textExtraction': JSString('cw.sortValueExtraction'),
         'selectorHeaders': 'thead tr:first th', # only plug on the first row
         }
+    handle_pagination = True
 
     def form_filter(self, divid, displaycols, displayactions, displayfilter,
                     paginate, hidden=True):