Commit fb455254 authored by gab's avatar gab

added role+bio fields to User

parent 122e640c
......@@ -3,11 +3,19 @@ from django.contrib.auth.models import AbstractUser
# Create your models here.
class CustomUser(AbstractUser):
ROLE_CHOICES = [
("STUDENT", "Student"),
("ORG", "Organization"),
("ALUMNI", "Alumni"),
("FACULTY", "Faculty"),
]
username = None
email = models.EmailField(unique=True, db_index=True)
first_name = models.CharField(blank=False, max_length=150)
last_name = models.CharField(blank=False, max_length=150)
role = models.CharField(max_length=7, blank=False, choices=ROLE_CHOICES)
bio = models.TextField(blank=True, max_length=150)
USERNAME_FIELD = 'email'
REQUIRED_FIELDS = []
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment