Chapter 2.5: Pagination

If rowcount is passed in query or manually added in, Genelet will display searched results in pages (i.e. pagination). Specifically,

  1. sending a request with rowcount=20 will turn on pagination
  2. if no pageno, then pageno=1 will be taken as the default.
  3. if total_force=1 in the model, the total number of rows and the total number of pages, totalno and maxpageno respectively, will be calculated for pageno=1.
  4. Use pageno=2 for the second page, and so on.
  5. sortby should be specifically defined, since the order of rows returned would depend on how they are sorted.
  6. If totalno is expected to change in real-time, you should arrange pagination in such a way that the first page, case 2 above, could be clicked often, so as to have totalno and maxpageno refreshed.