Hi, I'm trying to allow usernames that have '@' in them, so they can just be email addresses. Maybe this is a bad idea. ... But putting that aside for a second... The admin user forms don't validate with '@' in usernames, so I thought I'd try this, which I copied from an older post in this group.
from django.contrib.auth.admin import User, UserChangeForm, UserCreationForm, UserAdmin class OurUserChangeForm(UserChangeForm): username = forms.EmailField class OurUserCreationForm(UserCreationForm): username = forms.EmailField admin.site.unregister(User) UserAdmin.form = OurUserChangeForm UserAdmin.add_form = OurUserCreationForm admin.site.register(User, UserAdmin) But it doesn't work. The user form is still validating with the 'username' from the superclass, which is a RegexField. Is this working as designed? Are you not allowed to override a field? thanks, Rob -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.