.
This commit is contained in:
@@ -0,0 +1,18 @@
|
|||||||
|
# Generated by Django 3.2.8 on 2021-12-15 20:04
|
||||||
|
|
||||||
|
from django.db import migrations, models
|
||||||
|
|
||||||
|
|
||||||
|
class Migration(migrations.Migration):
|
||||||
|
|
||||||
|
dependencies = [
|
||||||
|
('rapids', '0040_alter_exam_valid_users'),
|
||||||
|
]
|
||||||
|
|
||||||
|
operations = [
|
||||||
|
migrations.AddField(
|
||||||
|
model_name='ciduseranswer',
|
||||||
|
name='score',
|
||||||
|
field=models.CharField(blank=True, choices=[('', 'Unmarked'), ('0', 'Incorrect'), ('1', 'Half mark'), ('2', 'Correct')], default='', max_length=1),
|
||||||
|
),
|
||||||
|
]
|
||||||
@@ -654,6 +654,13 @@ class CidUserAnswer(models.Model):
|
|||||||
created = models.DateTimeField(auto_now_add=True)
|
created = models.DateTimeField(auto_now_add=True)
|
||||||
updated = models.DateTimeField(auto_now=True)
|
updated = models.DateTimeField(auto_now=True)
|
||||||
|
|
||||||
|
score = models.CharField(
|
||||||
|
max_length=1,
|
||||||
|
choices=Answer.MarkOptions.choices,
|
||||||
|
default=Answer.MarkOptions.UNMARKED,
|
||||||
|
blank=True
|
||||||
|
)
|
||||||
|
|
||||||
def __str__(self):
|
def __str__(self):
|
||||||
try:
|
try:
|
||||||
exam = self.exam
|
exam = self.exam
|
||||||
|
|||||||
Reference in New Issue
Block a user