Closed Sabr1n4W closed 1 month ago
Extended Bug description The PrimeVue paginator's first index and the usePaginator first index values get out of sync on a failed page loading attempt.
usePaginator
class maintains a first
value that is always set after a successful request.first
value in usePaginator
changes, it updates the first
index in the PrimeVue paginator, resulting in a corresponding page change.Step by step
first
index in usePaginator
is set correctly.first
index in the PrimeVue paginator is still updated, but the first
index in usePaginator
remains unchanged.usePaginator
values are updated. However, since the usePaginator
values were not updated during the failed request, no change is propagated back to the PrimeVue paginator.
Describe the bug The paginations show an incorrect page after the data has been reloaded without error after an error has occurred when changing pages. The data is reloaded for the previous active page (page before the page change) but the active page shown is the new active page (page after the page change).
To Reproduce Steps to reproduce the behavior:
E.g. An error occured when switching from the first page to the second page of the pagination. Now reload the data through the reload button (data is reloaded for first page). After that the pagination still shows the second page as the active page.
Expected behavior
Option (set pagination page to previous page) Reset the active page within the pagination to the page with which the data was reloaded.
Option (reload data with new active page) Reload the data with the page that will be shown as active page.
Additional context This has not been tested for all paginations yet.
Currently this behaviour was found in: