DataGrid Pagination

0

Please any could help me like realising a pagination with datagrid since as a result of a query I can have up to 1000 registries, but I only want to show of 20 in 20

Thanks

Oscar

edc's picture

re: Pagination Example

Your right, the liveview and livevariable do not appear to be adding any value in this project.

The dataGrid1 is bound to the getCustomerByPageVar and not using the data returned from the liveView at all.

I have little question

I have little question regarding the Paginationv4 project.
How does the dataGrid1 get filled automatically by the getCustomerVar liveVariable, where his dataset is bind to getCustomerByPageVar Service Variable.
The Service variable is set to get data from the custom query calling only Customer table. Where the Datagrid is able to auto get his columns from the liveView defined in the liveVariable.

edc's picture

Paging - HQL Thread

Here is an earlier thread in which Mavirocco sorted out the HQL for row counts.

http://dev.wavemaker.com/forums/?q=node/1718

edc's picture

Pagination v4

Dharamang has put an example of paging in v4 together, attached.

In doing such, we found that the dataSetSize property is not being correctly returned. MAV-2013 has been filed for that. The attached example therefore will 'run over the edge' of the data set, trying to display rows beyond the count of the data set. This project will be updated when MAV-2013 is fixed.

Custom HQL queries or stored procedures could be used to select a row count as a workaround.

In the meantime, the attached example should be helpful.

AttachmentSize
PaginationV4.zip 59.4 KB
edc's picture

v4 version of Pagination

While this project does upgrade to 4.0 for the most part, we will post a v4 version of this project directly.  It will be better. Thank you.

liveVariable

this example is using serviceVariable. Anyone was able to do the same with LiveVariable ?

Thanks

malamut's picture

This was exactly my thirst

This was exactly my thirst question when I started to use Wavemaker:

see; http://dev.wavemaker.com/forums/?q=node/1957

Please be aware that this was a sample for v3.2 but it gives you an idea.