add exam collections
This commit is contained in:
@@ -28,6 +28,7 @@ from django.contrib.contenttypes.fields import GenericRelation
|
||||
from generic.models import (
|
||||
CidUser,
|
||||
CidUserGroup,
|
||||
ExamCollection,
|
||||
ExamUserStatus,
|
||||
QuestionBase,
|
||||
Site,
|
||||
@@ -648,6 +649,8 @@ class Exam(ExamBase):
|
||||
|
||||
exam_user_status = GenericRelation(ExamUserStatus)
|
||||
|
||||
exam_collection = models.ForeignKey(ExamCollection, blank=True, null=True, on_delete=models.SET_NULL, related_name="rapids_exams")
|
||||
|
||||
def get_normal_abnormal_breakdown(self):
|
||||
# Inefficient but more extendible
|
||||
questions = self.exam_questions.all()
|
||||
|
||||
Reference in New Issue
Block a user