-
Notifications
You must be signed in to change notification settings - Fork 126
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
Move to prev/next page functionality is broken #307
Comments
Hi, I'm still having an issue with this it seems the grid field order is still not behaving the way it should. Currently using silverstripe version 4.12 and PHP 8.0. In a customised grid field as shown in the clip below shows some interesting behaviour. This grid has 3 pages of grid field items, all of which are given a letter as a title. Trying to move the 'z' grid to the next page moves it to the last page and also changes the order of most of the exisiting grid items. The 'z' grid item has also been moved to page 3 instead of 2. Moving it back to page 2 seems to work but then the item has moved slightly above the mouse and can't be dropped onto the page arrows. Screen.Recording.2023-02-13.at.15.52.21.mov |
FIX: Fixed move to prev/next page functionality (fixes #307)
PR merged. This will be automatically tagged by GitHub actions |
It looks to me like
GridFieldOrderableRows::reorderItems()
was updated from taking a list of IDs and putting them in order, to taking an associative array or pre-ordered sort/id values.handleMovetoPage()
currently generates an indexed array of IDs that are in the correct order, but as they don’t have any sort valuesreorderItems()
doesn’t deal with them properly.PRs
The text was updated successfully, but these errors were encountered: