Skip to content

Commit

Permalink
Add RecognizedCourse model (#878)
Browse files Browse the repository at this point in the history
  • Loading branch information
GrasshopperBears committed Nov 23, 2021
1 parent 55ab6bd commit dc6790c
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion apps/planner/models.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from django.db import models
from django.core.validators import MinValueValidator, MaxValueValidator

from apps.subject.models import Department
from apps.subject.models import Department, Course

class MajorGraduationRequirement(models.Model):
class MajorType(models.TextChoices):
Expand All @@ -18,3 +18,8 @@ class MajorType(models.TextChoices):
mandatory_major = models.IntegerField(validators=[MinValueValidator(0), MaxValueValidator(200)])
elective_major = models.IntegerField(validators=[MinValueValidator(0), MaxValueValidator(200)])
elective_basic = models.IntegerField(validators=[MinValueValidator(0), MaxValueValidator(200)])


class RecognizedCourse(models.Model):
original_course = models.ForeignKey(Course, related_name="recognized_course_original_course")
recognized_course = models.ForeignKey(Course, related_name="recognized_course_recognized_course")

0 comments on commit dc6790c

Please sign in to comment.