gridx
Legend: Array Boolean Constructor Date DomNode Error Function Namespace Number Object RegExp Singleton String

gridx.modules.pagination.Pagination

Object » _Module » gridx.modules.pagination.Pagination
dojo.require("gridx.modules.pagination.Pagination");
Defined in gridx/modules/pagination/Pagination.js

This module does not include any UI buttons for pagination, so that various kinds of pagination UI implementations can benifit from this module.

Property Summary

Method Summary

  • _onSizeChange(size)
  • _updateBody(noRefresh)
  • currentPage() returns Integer Get the index of current page.
  • filterIndexesInPage(indexes, page) returns Integer[] Filter out the indexes that are in the given page.
  • firstIndexInPage(page) returns Integer Get the index of the first row in the given page.
  • getAPIPath()
  • gotoPage(page) Set the current page
  • indexInPage(index) returns Integer Get the row index in page by overall row index
  • isAll() returns Boolean Check if the grid is currently showing all rows (page size set to 0).
  • lastIndexInPage(page) returns Integer Get the index of the last row in the given page.
  • load()
  • pageCount() returns Integer Get the current count of pages.
  • pageOfIndex(index) returns Integer Get the index of the page that the given row is in.
  • pageSize() returns Integer Get current page size
  • preload()
  • setPageSize(size) Set page size (count of rows in one page)

Event Summary

Attached Objects

Properties

rowMixin
Overrides _Module

Methods

_onSizeChange
Overrides _Module
ParameterTypeDescription
size
_updateBody
Overrides _Module
ParameterTypeDescription
noRefresh
currentPage
Overrides _Module
Returns Integer: The index of current page.
Get the index of current page.
filterIndexesInPage
Overrides _Module
Returns Integer[]: A subset of indexes that appear in the given page.
Filter out the indexes that are in the given page.
ParameterTypeDescription
indexesInteger[]An array of row indexes.
pageIntegerA page index
firstIndexInPage
Overrides _Module
Returns Integer: The index of the first row in the page. If page is not valid, return -1.
Get the index of the first row in the given page.
ParameterTypeDescription
pageIntegerThe index of a page.
getAPIPath
Overrides _Module
gotoPage
Overrides _Module
Set the current page
ParameterTypeDescription
pageIntegerA page index
indexInPage
Overrides _Module
Returns Integer: The row index in page
Get the row index in page by overall row index
ParameterTypeDescription
indexIntegerThe row index
isAll
Overrides _Module
Returns Boolean: Whether the grid is showing all rows.
Check if the grid is currently showing all rows (page size set to 0).
lastIndexInPage
Overrides _Module
Returns Integer: The index of the last row in the given page.
Get the index of the last row in the given page.
ParameterTypeDescription
pageIntegerThe index of a page
load
Overrides _Module
pageCount
Overrides _Module
Returns Integer: The current count of pages.
Get the current count of pages.
pageOfIndex
Overrides _Module
Returns Integer: The page index
Get the index of the page that the given row is in.
ParameterTypeDescription
indexIntegerThe row index
pageSize
Overrides _Module
Returns Integer: The current page size
Get current page size
preload
Overrides _Module
setPageSize
Overrides _Module
Set page size (count of rows in one page)
ParameterTypeDescription
sizeIntegerThe new page size

Events

onChangePageSize
Overrides _Module
Fired when the page size is changed
onSwitchPage
Overrides _Module
Fired when switched to another page.