Version 19 (modified by Fran Boon, 13 years ago) ( diff )


Server-Side Pagination

Currently we do all pagination client-side which won't be possible to keep doing as we accumulate more data

This will be needed for:

fractalis has offered to look at this


  • The Back-end is now done for HTML representation
  • The Back-end was already done for JSON representation
  • The Front-end still needs doing

Front-end implementation

Client-side, we need to add these options to views/dataTables.html:

    "bProcessing": true,
    "bServerSide": true,
    "sAjaxSource": "{{=URL(r=request, c='module', r='resource', vars={'...':'...'})}}"

JSON Back-end implementation

  • Support already present in modules\
  • http://S3_PUBLIC_URL/module/resource.json?limit=x&start=y

HTML Back-end implementation

Patched the models\01_RESTlike_Controller to support http://S3_PUBLIC_URL/module/resource?limit=x&start=y

     if request.vars.limit:
        limit = int(request.vars.limit)
        if request.vars.start:
            start = int(request.vars.start)
            limitby = (start, start + limit)
            limitby = (0, limit)
        limitby = None
items =, query=query,

Other Options

  • Maybe look at the currently-unused modules/
  • pagenav in models\01_RESTlike_Controller seems unused currently...was an older implementation of a webgrid...can probably be removed.


Note: See TracWiki for help on using the wiki.