- Python 3.9+, Django 3.2
- To use this package, need to add
admin.py
andtemplates
to the project. - Set the order of the models in the desired order. It should be a dictionary -
ADMIN_APPS
, where the key is the title of the block, and the values are a tuple of models (either the name of the model inCamelCase
, orcapfirst
for theverbose_name_plural
of the model). - Change main
urls.py
(path("admin/", admin.site.urls),
->path("admin/", admin_site.urls)
(fromadmin.py
)) - Change
admin.site.register
toadmin_site.register
and@admin.register
toadmin_site.register
inadmin.py
of apps
Example:
ADMIN_APPS = {
"Some group": ("Users",), # capfirst
"Also group": ("Contact", "User", "Folder"), # CamelCase
}