THM-Health / PILOS

PILOS is an easy-to-use open source front-end for BigBlueButton servers with a built-in load balancer. Docker-Images: https://hub.docker.com/r/pilos/pilos
https://thm-health.github.io/PILOS/
GNU Lesser General Public License v2.1
51 stars 18 forks source link

Wrong page shown in paginations after error occured while changing pages #1291

Closed Sabr1n4W closed 1 month ago

Sabr1n4W commented 2 months ago

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:

  1. Make sure an error occurs when switching to another page
  2. Now reload the data through the reload button (data will be reloaded for the previous active page)
  3. After that the pagination shows the new active page as active page and not the previous with which the data was reloaded.

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

  1. Option (set pagination page to previous page) Reset the active page within the pagination to the page with which the data was reloaded.

  2. 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:

SamuelWei commented 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.

Step by step