The Django admin site has Authentication and Authorization which has users and groups. When we add models, they are displayed below this. Is it possible to add a model immediately below Groups, Users? And how can we change the existing names?
相关问题
- Django __str__ returned non-string (type NoneType)
- Django & Amazon SES SMTP. Cannot send email
- Django check user group permissions
- Django restrict pages to certain users
- UnicodeEncodeError with attach_file on EmailMessag
相关文章
- Profiling Django with PyCharm
- Why doesn't Django enforce my unique_together
- MultiValueDictKeyError in Django admin
- Django/Heroku: FATAL: too many connections for rol
- Django is sooo slow? errno 32 broken pipe? dcramer
- Django: Replacement for the default ManyToMany Wid
- Upgrading transaction.commit_manually() to Django
- UnicodeEncodeError when saving ImageField containi
Try to override admin
index
template ...change this
{% for app in app_list %}
to{% for app in app_list reversed %}
or sort it in some custom way ...EDIT
seems I've found easier solution :)
https://github.com/mishbahr/django-modeladmin-reorder
It's a bit tricky, takes some work, and it's going to trigger some warning in Django 1.8. But this is basically what you do:
Suppose you have an application
myauth
that will override the defaultdjango.contrib.auth
application...In
myauth/models.py
do this:ExtraModel
is the model you want to add.In
myauth/__init__.py
do this:In
myauth/admin.py
do this:And in your
settings.py
, withinINSTALLED_APPS
comment out the line:and just add your application: