roykrish
19 Jan 2012, 9:36 PM
Hi,
I am new to Sencha, and tried to write a sample application using Grid. I followed the example given in 'Getting started guide' and get one simple application up and running using MVC architecture, with one view only which is nothing but a plain Grid. My datastore is a json file.
Now, I want to use Paging in my grid panel. I followed this link http://docs.sencha.com/ext-js/4-0/#!/guide/grid and did whatever is mentioned here under the 'Paging' Section .
[1] I used 'pageSize' and 'totalProperty' in my store.
[2] I modified my json file as mentioned in the example.
[3] I put the dockedItem section in my view.
What is happening is that in my Grid View I am getting the paging toolbar. The toolbar shows all the buttons correctly. The only problem is that every time the grid is loading is all the records. I have total 9 records in my static JSON file, and my pageSize is 4. I want the grid to show first 4 records only at the beginning and when I go to page 2 it should show me from 4 to 8 and so on. But it is always showing up all the 9 records.
Could someone please guide me, that what I am missing here.
Thank You !!
I am new to Sencha, and tried to write a sample application using Grid. I followed the example given in 'Getting started guide' and get one simple application up and running using MVC architecture, with one view only which is nothing but a plain Grid. My datastore is a json file.
Now, I want to use Paging in my grid panel. I followed this link http://docs.sencha.com/ext-js/4-0/#!/guide/grid and did whatever is mentioned here under the 'Paging' Section .
[1] I used 'pageSize' and 'totalProperty' in my store.
[2] I modified my json file as mentioned in the example.
[3] I put the dockedItem section in my view.
What is happening is that in my Grid View I am getting the paging toolbar. The toolbar shows all the buttons correctly. The only problem is that every time the grid is loading is all the records. I have total 9 records in my static JSON file, and my pageSize is 4. I want the grid to show first 4 records only at the beginning and when I go to page 2 it should show me from 4 to 8 and so on. But it is always showing up all the 9 records.
Could someone please guide me, that what I am missing here.
Thank You !!