jrief / django-admin-sortable2

Generic drag-and-drop ordering for objects in the Django admin interface

Home Page:https://django-admin-sortable2.readthedocs.io/en/latest/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Javascript API less dependent on UI events

hovi opened this issue · comments

Hi,

I checked the sources for the project to look for some kind of API, that allows reordering using different ways.
A few examples:

  • A button next to an item in admin table "make this primary", which would automatically set this item in the first position.
  • Similarly a button to move the item to the last position.
  • Reordering, that reacts to changes in different parts of the formset.

Correct me if I looked wrong, but it's pity, that I can't use the already nice working API to do this functionality, since the functionality is pretty much already there, just mostly hooked on drag & drop events.

The functionality is not complicated and I can just write my own code, but you can consider that next time you refactor your frontend code :-)

Edit: I see there is a related issue: #300