Replies: 2 comments 2 replies
-
I think I don't understand what you mean. Is totalRecords = 5 or rows = 5? |
Beta Was this translation helpful? Give feedback.
1 reply
-
Same problem here (not showing pages on :totalRecords='111' set. Resolved by adding lazy as @sajjad201 points out https://stackblitz.com/edit/cryfmj?file=src%2FApp.vue Created PR |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I am using pagination in primevue datatable as it:
<DataTable ref="dt" :value="dataItems" dataKey="id" :loading="loading1" :paginator="true" :totalRecords="50" :rows="5" :pageLinkSize="50" @page="handlePagination">
What its Doing
It shows no link to next/prev pages if server returns 5 data rows.
if server return 10 rows, then it is showing 2 page links in pagination bar and so on...
What it should do
There should be page links based on total count. f
For example, if server return totalRows=50 then it should show 10 page links in pagination bar and 5 data rows on each page so If user click on page 2, 3, 4... the request should go to server to fetch the related page data.
Event Data on clicking the page link
{ "originalEvent": { "page": 1, "first": 4, "rows": 4, "pageCount": 2 }, "first": 4, "rows": 4, "sortField": null, "sortOrder": null, "multiSortMeta": [], "filters": {}, "pageCount": 2, "page": 1 }
What changes should I made to generate links according to totalRecords so I can send request to server to get other pages data as well.
Is it possible with https://primevue.org/paginator
Beta Was this translation helpful? Give feedback.
All reactions