Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pagination model not updated when per page is updated #2987

Closed
atrunelle opened this issue Apr 2, 2019 · 4 comments · Fixed by #2993
Closed

Pagination model not updated when per page is updated #2987

atrunelle opened this issue Apr 2, 2019 · 4 comments · Fixed by #2993

Comments

@atrunelle
Copy link
Contributor

When using b-pagination component, if the number of item per page is updated, the current page is not updated.

How to reproduce:
See https://codesandbox.io/s/7j017j3yy0
Click on page 3, change the number of page with the select to All. The current page is still 3 and no items are displayed in the table.

I found this after upgrading from RC 12 to RC 16.

  • Operating system and version: Mac OS X
  • Browser and version: Chrome
  • Version of BootstrapVue that you are using: RC 16
@tmorehouse
Copy link
Member

We may need to add in a watcher for the perPage prop.

@tmorehouse tmorehouse self-assigned this Apr 2, 2019
@tmorehouse
Copy link
Member

tmorehouse commented Apr 2, 2019

@atrunelle Actually there is a typo in your codesandbox on the current page binding on the b-table. It should be currentPageValue

@atrunelle
Copy link
Contributor Author

@tmorehouse Hum, I don't see any currentPageValue in my sandbox. Maybe it was not saved properly (as I had some before). Could you have another look?

@tmorehouse
Copy link
Member

tmorehouse commented Apr 2, 2019

It must have been a previous version of the sandbox that I was looking at.

It looks like we aren't emitting the current page value via the model when the previous current page is no longer available.

I should be able to get a fix for this tonight.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants