extjspaginationextjs4.1

Paging issue in ExtJS 4.1


I have figure out that when the grid has paging property you should not sent the metaData property second time from the server. Because if you send it second time paging breaks. I only needs to send at first. How should I overcome this problem? The problem comes from this code that I have found it in the documentation.

listeners: { //under the store
            'metachange': function(store,meta){
            grid.reconfigure(store,meta.columns);
            }  

Solution

  • A proposal:

    listeners: { //under the store
        'metachange': function(store,meta){
         if ( !this.meta )
         {
             this.meta = meta;
             grid.reconfigure(store,meta.columns);
         }
    }