Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class QuizQuestion(models.Model):
- class Meta:
- verbose_name = "Quiz Question"
- verbose_name_plural = "Quiz Questions"
- def __str__(self):
- return str(self.question)
- quiz = models.ForeignKey(Quiz, on_delete=models.CASCADE)
- question = models.TextField("Question")
- topic = models.ForeignKey("Topic", null=True, blank=True, on_delete=models.CASCADE)
- image = models.ImageField("Image", null=True, blank=True)
- points = models.IntegerField("Point Value", null=True, blank=True)
- created = models.DateField("Created", auto_now=True)
- updated = models.DateField("Created", auto_now_add=True)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement