Pagination doesn't work when a user don't has permission to reorder the view, or when the 'Lock' option in draggable table is set.
Only the first page is showed ever, clicking on next, previous, last ... always shows the first page.
This only happens for those users, not for a admin user that has permission to reorder the draggable view, in this case the pagination works properly.
I suppose this isn't the correct answer but I fixed it in my site changing the code in the hook draggable_views_pre_execute, when is altered the pager for only those users with 'Allow Reordering' (and no 'lock') to add some extra rows. I put the same code without the info['pager']['offset'] to the rest of users, and the pager 'returns to live' .
| Comment | File | Size | Author |
|---|---|---|---|
| #1 | draggableviews-669674.patch | 2.19 KB | sevi |
| code.diff | 871 bytes | alambike |
Comments
Comment #1
sevi commentedYes, it is the correct answer. Thanks for the patch.
This issue only applies to simple lists (parent field is set to '-none-'), not to hierarchies.
I modified your patch a little bit. The
if ($first_index < 0) $first_index = 0;is not needed because $first_index is positive for sure. (see surroundingif ($info['pager']['items_per_page'] > 0) {; views ensures that$info['pager']['current_page']is positive)Greetings,
sevi
Comment #2
sevi commentedComment #3
alambike commentedOk, great!. The new patch works for me.
We should wait some time to close the issue or close it now?
Thanks for this wonderful module.
Greetings.
Comment #4
sevi commentedCommitted to Drupal-6--3 branch: http://drupal.org/cvs?commit=307954
I'll set the status to "fixed". It will be closed automatically in 2 weeks..
Thanks for the patch :)
Greetings,
sevi
PS: I forgot mentioning you in the cvs message :( ..but i'll mention you in the 6--3-4 release notes :)
Comment #5
alambike commentedOk, thanx again!