Make users not active by default, requiring email activation

This commit is contained in:
Keannu Bernasol 2023-07-04 19:36:29 +08:00
parent 267e331be7
commit 5840d3f95c
3 changed files with 20 additions and 0 deletions

View file

@ -0,0 +1,18 @@
# Generated by Django 4.2.2 on 2023-07-04 11:33
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('accounts', '0004_alter_customuser_course_alter_customuser_semester_and_more'),
]
operations = [
migrations.AlterField(
model_name='customuser',
name='is_active',
field=models.BooleanField(default=False),
),
]

View file

@ -33,6 +33,7 @@ class CustomUser(AbstractUser):
# Username inherited from base user class
# Password inherited from base user class
# is_admin inherited from base user class
is_active = models.BooleanField(default=False)
is_student = models.BooleanField(default=True)
is_studying = models.BooleanField(default=False)
is_banned = models.BooleanField(default=False)

View file

@ -196,4 +196,5 @@ if (DEBUG):
else:
DOMAIN = 'stude'
SITE_NAME = 'Stud-E'