how to implement pagination in dojox.datagrid

163 Views Asked by At

i have a req of displaying pagination in the dojox.datagrid i tried searching but no luck. Wanted to know whether pagination is possible in dojox.datagrid Can some one confirm this please.

1

There are 1 best solutions below

1
bajji On

you have to use

dojo.require("dojox.grid.enhanced.plugins.Pagination");

In your grid

var grid = new dojox.grid.EnhancedGrid({
        id: 'grid',
        store: store,
        structure: layout,
        rowSelector: '20px',

        plugins: {
          pagination: {
              pageSizes: ["25", "50", "100", "All"],
              description: true,
              sizeSwitch: true,
              pageStepper: true,
              gotoButton: true,
                      /*page step to be displayed*/
              maxPageStep: 4,
                      /*position of the pagination bar*/
              position: "bottom"
          }
        }
    }, document.createElement('div'));