puidatatable how to perform paging with ajax loading data

jQuery UI Widgets
Post Reply
wureka
Posts: 3
Joined: 08 May 2014, 23:13

21 Aug 2015, 05:33

I hope puidatatable to have the below work model:
1. When click a page (ex:page 7) in a puidatatable with paginator enable
2. a function of event is triggered and in the function I can use ajax to load data of page 7 and refresh to datasources in puidatatable without reloading full html page.
I can not find relevant description in puidatatable demo page.

I know there is an alternative way.
A puidatatable works with standalone Paginator component.
But when I use ajax to load new page data in the event function of Paginator,
I don't know how to update the new page data back to the puidatatable's datasources.

cagatay.civici
Prime
Posts: 18616
Joined: 05 Jan 2009, 00:21
Location: Cybertron
Contact:

27 Aug 2015, 11:29

See the remote lazy demo please;

http://www.primefaces.org/primeui/#datatable

wureka
Posts: 3
Joined: 08 May 2014, 23:13

28 Aug 2015, 13:20

optimus.prime wrote:See the remote lazy demo please;

http://www.primefaces.org/primeui/#datatable
Hi,
Thank you for your information. I have tried that demo.
But I found when I clicked a page, it could not trigger the event in datasources for reloading data

Now suppose the paginator is set pageLinks as 10, and the datasource loads 500 records data at the first time when page is being loaded. So on the web page, you will see that there are totally 50 pageLinks (500/10 = 50).
However, if I want to see page 51, there is no way to do it.

Don't tell me that I can load more than 500 records at the first time page is being loaded. I think that is not reasonable because If I totally have 20000 records of data or more, well, I can not load them at the first time.

Post Reply

Return to “PrimeUI”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 17 guests