0

I am using django-allauth to sign people in/up using Google.

However, I'd like to put some additional constraints on who is able to enter the system (in my case, only people with Google account on specified subdomain).

What is the best place to add those?

Almad
  • 5,753
  • 7
  • 35
  • 53

1 Answers1

0

Step 1: In forms.py, create a SignupForm.

Step 2: In SignupForm, create a signup() method with your custom validation logic.

Step 3: Point ACCOUNT_SIGNUP_FORM_CLASS to your SignupForm.

See here for more info.

Community
  • 1
  • 1
mcastle
  • 2,882
  • 3
  • 25
  • 43