quiz/models.py
changeset 39 0fa055b8ea98
parent 28 456b7b9e3d13
child 43 265ed367e8cc
equal deleted inserted replaced
38:307c6887cc67 39:0fa055b8ea98
    27     """ A model for holding answers submitted by users.
    27     """ A model for holding answers submitted by users.
    28     """
    28     """
    29 
    29 
    30     question = models.ForeignKey(QuestionBank)
    30     question = models.ForeignKey(QuestionBank)
    31     submitted_ans = models.TextField()
    31     submitted_ans = models.TextField()
    32     is_correct = models.BooleanField()
    32     is_correct = models.BooleanField(default=False)
    33 
    33 
    34 class Quiz(models.Model):
    34 class Quiz(models.Model):
    35     """ A model to hold the proceeding of a quiz.
    35     """ A model to hold the proceeding of a quiz.
    36     """
    36     """
    37 
    37