1

I would like to remove the "Account" section from the Django Admin page.

I can't figure out what model I would need to unregister().

enter image description here

James Parker
  • 2,095
  • 3
  • 27
  • 48

1 Answers1

0

It seems you are using a third party application django-user-accounts.

To disable this feature, add this into your admin.py file:

from django.contrib import admin
from account.models import (
 Account,
 AccountDeletion,
 EmailAddress,
 PasswordExpiry,
 PasswordHistory,
)

admin.site.unregister(Account)
admin.site.unregister(AccountDeletion)
admin.site.unregister(EmailAddress)
admin.site.unregister(PasswordExpiry)
admin.site.unregister(PasswordHistory)

If you do not needs this application, remove it from your INSTALLED_APPS settings:

INSTALLED_APPS = (
    # ...
    "account",
    # ...
)
Xavier Brassoud
  • 697
  • 6
  • 14