-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmodels.py
21 lines (18 loc) · 870 Bytes
/
models.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
class User:
def __init__(self, firstname, lastname, email, password, date_of_birth):
self.firstname = firstname
self.lastname = lastname
self.email = email
self.password = password
self.date_of_birth = date_of_birth
class Student(User):
def __init__(self, firstname, lastname, email, password, date_of_birth, parent_id, grade):
super().__init__(firstname, lastname, email, password, date_of_birth)
self.parent_id = parent_id
self.grade = grade
class Parent(User):
def __init__(self, firstname, lastname, email, password, date_of_birth):
super().__init__(firstname, lastname, email, password, date_of_birth)
class Teacher(User):
def __init__(self, firstname, lastname, email, password, date_of_birth):
super().__init__(firstname, lastname, email, password, date_of_birth)