I do not see a way to do this in allauth yet, except by setting up the code for your project.
Unlike other answers, the code in allauth.account.forms inherits SignUpForm from your user registration form:
# in allauth.account.forms.py class BaseSignupForm(_base_signup_form_class()):
BaseSignupForm is used both for "standard" registration, and for registration in a social account. In the "standard" registration, it is subclassed as SignUpForm and adds password fields:
# in allauth.account.forms.py class SignupForm(BaseSignupForm): def __init__(self, *args, **kwargs): super(SignupForm, self).__init__(*args, **kwargs) self.fields['password1'] = PasswordField(label=_("Password")) if app_settings.SIGNUP_PASSWORD_ENTER_TWICE: self.fields['password2'] = PasswordField( label=_("Password (again)"))
So, I tried to hide the field in the view template, but no luck. Perhaps using FormHelper in crispyforms is a way.
source share