Opened 5 years ago
Closed 5 years ago
#31857 closed Bug (invalid)
Admin side_bar showing up in login form with django-otp.
| Reported by: | Fernando Cordeiro | Owned by: | nobody |
|---|---|---|---|
| Component: | contrib.admin | Version: | 3.1 |
| Severity: | Normal | Keywords: | admin |
| Cc: | Triage Stage: | Unreviewed | |
| Has patch: | no | Needs documentation: | no |
| Needs tests: | no | Patch needs improvement: | no |
| Easy pickings: | no | UI/UX: | no |
Description (last modified by )
When I upgrade to Django 3.1, the new admin navbar started to appear in the login screen. Look:
Please note I'm using the django_otp package, that overrides the django's admin.site.__class__ ith their own OTPAdminSite class. This only happens with that package.
Nevertheless, this could potentially be happening with any other package. Given how sensitive the admin information is, I believe it's safer to set AdminSite.enable_nav_sidebar to False so people's models are not exposed.
Attachments (1)
Change History (3)
by , 5 years ago
| Attachment: | admin_nav_bar.png added |
|---|
comment:1 by , 5 years ago
| Description: | modified (diff) |
|---|
comment:2 by , 5 years ago
| Resolution: | → invalid |
|---|---|
| Status: | new → closed |
| Summary: | Admin side_bar showing up in login form → Admin side_bar showing up in login form with django-otp. |
It's an issue in django-otp not is Django. enable_nav_sidebar can be easily set to False in OTPAdminSite, but IMO they should rather override nav-sidebar block in login.html (which is quite specific). Please report this in their issue tracker.
Moreover I don't think that django-otp supports Django 3.1, it's not tested.
Snapshot of admin login with navbar activated