django-admin-ordering
django-admin-ordering copied to clipboard
Paginated admin does not respect ordering
If I change this setting:
https://docs.djangoproject.com/en/dev/ref/contrib/admin/#django.contrib.admin.ModelAdmin.list_per_page
Then on the second page, if I drag any items, it will reset ordering to 10, 20, 30... and so on, which if saved, will conflict with the first page. Is it possible to discern the minimum (or maximum for reverse-ordered fields) value from the form on the page and use that as the starting value?
Yes, that may be a problem. A related problem is that it is also possible to reorder filtered lists. Both may produce unexpected results.
Generally, I'm not using orderable admins with more than a handful of entries so this limitation didn't cause much pain to me yet.
I'm personally leaning towards documenting this as a limitation (and telling people they should raise their list_per_page
setting when it is a problem) but maybe your proposal would work too?