Re: default is_active to true on new users

2010-07-09 Thread Alexandre González
I don't know, but try something as this to the help_text: class RegistrationFormTOSAndUniqueEmail(RegistrationFormTermsOfService, RegistrationFormUniqueEmail): class MyUserAdminForm(forms.ModelForm): def __init__(self, *args, **kwargs): self.fields['is_staff'].help_text = _("Test.")

Re: default is_active to true on new users

2010-07-09 Thread Alexandre González
Hi! Perhaps you can do it easily with signals instead override the save method, take a look to this: http://www.ibm.com/developerworks/opensource/library/os-django-admin/index.html Good luck and ask again if they don

Re: default is_active to true on new users

2010-07-08 Thread Jacob Fenwick
I tried something like this: *models.py class MyUser(User): pass *admin.py class MyUserAdminForm(forms.ModelForm): is_staff = models.BooleanField(_('staff status'), default=True, help_text=_("Test.")) class Meta: model = User class MyUserAdmin(UserAdmin): form = Publishe

Re: default is_active to true on new users

2010-07-08 Thread Jacob Fenwick
So one method I found is to use the custom validation from a form in the ModelAdmin: http://docs.djangoproject.com/en/1.2/ref/contrib/admin/#adding-custom-validation-to-the-admin However, this only seems to work on edits, not on adds. How can I make this work on adds? Jacob On Thu, Jul 8, 2010

default is_active to true on new users

2010-07-08 Thread Jacob Fenwick
I'm looking for a way to automatically set is_active to true for new users that are added through the admin interface. I tried to subclass the User class and set the is_active default to true but apparently you can't override fields in a parent model: http://docs.djangoproject.com/en/1.2/topics/db