Opened 9 years ago
Closed 9 years ago
#25557 closed Bug (duplicate)
Fix the UserCreationForm for custom user model
Reported by: | Pierre Dulac | Owned by: | nobody |
---|---|---|---|
Component: | contrib.auth | Version: | 1.9a1 |
Severity: | Normal | Keywords: | admin, custom, user |
Cc: | Triage Stage: | Unreviewed | |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
The admin user creation form was trying to set the username
field of the User model, but that field does not exists for sure in case of a custom user model.
But this *field* should be referred as User.USERNAME_FIELD
to fully support Usual and Custom user models.
I've prepared a pull request associated to it : https://github.com/django/django/pull/5432
Cheers
Change History (1)
comment:1 by , 9 years ago
Component: | contrib.admin → contrib.auth |
---|---|
Resolution: | → duplicate |
Status: | new → closed |
Summary: | Fix the admin user creation form for custom user model → Fix the UserCreationForm for custom user model |
Note:
See TracTickets
for help on using tickets.
Duplicate of #19353. Tests and documentation updates are also required as noted in that ticket if you'd like to try to finish it.