5π
Sure, here is an example of admin.py file with up and down links to change items order:
https://github.com/alexvasi/django-simplemenu/blob/master/simplemenu/admin.py
Basically, you just need to override get_urls method to add your custom views (move_up
and move_down
in this example).
More famous example would be django-treemenus, but there is some extra code to support older versions of django.
12π
Check this: django-orderedmodel.
This is a really simple implementation of abstract base class for items which can be ordered with admin interface. No external dependencies and easy to use.
- Why not use enctype="multipart/form-data" always?
- Using Django auth User model as a Foreignkey and reverse relations
2π
You can use django-admin-sortable2 to easily change the order of items including inline items as well.
- Nested loop in Django template
- Count lines of code in a Django Project
- Got AttributeError when attempting to get a value for field on serializer
- Django crispy forms with jinja2
- Valid use case for django admin?
0π
You can check:
- Difficulty overriding Django Admin template
- Django make_password too slow for creating large list of users programatically
- Using django-rest-interface with http put
- Custom label on ModelChoiceField form field
- Django run tasks (possibly) in the far future
0π
In case someone else is seeking the solution for that issue in 2017, I found the great package Django Admin Sortable
- Django cache framework. What is the difference between TIMEOUT and CACHE_MIDDLEWARE_SECONDS?
- Django: taking input and showing output in the same page
- Django admin β how to get all registered models in templatetag?