allowed course foreignkey in Assignments app to be nullable

parent d220187f
......@@ -10,7 +10,7 @@ class Course(models.Model):
return self.course_title
class Assignment(models.Model):
course = models.ForeignKey(Course, on_delete=models.CASCADE,default="1")
course = models.ForeignKey(Course, on_delete=models.CASCADE,default=None,null=True,blank=True)
name = models.CharField(max_length=100)
description = models.CharField(max_length=500)
max_points = models.IntegerField()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment