Reputation: 1043
I have django-admin-interface installed in my django app. I configured layout using this plugin and I would like to hide it from admin panel. My goal is to store basic settings in database. Is it possible?
I can't find any relations in my code to this plugin. There is only one place in my code (settings.py) where phrase admin_interface appears.
INSTALLED_APPS = [
'mainapp.apps.MainappConfig',
'admin_interface',
'colorfield',
'flat_responsive',
'django.contrib.admin',
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'django_extensions',
'smart_selects',
'activatable_model',
'bootstrap3',
'mainapp.apps.ConstanceConfig',
'constance.backends.database',
'kronos',
'ckeditor',
'django_admin_listfilter_dropdown',
]
Is is possible to hide this area in admin panel?
Upvotes: 2
Views: 3272
Reputation: 4194
You can use unregister
in your admin.py
.
from django.contrib import admin
from admin_interface.models import Theme
admin.site.unregister(Theme)
If you have multiple apps and hence multiple admin.py, then adding this snippet in anyone of them will hide the app
Upvotes: 5