feat: add marker feedback field to UserAnswer model and update forms accordingly

This commit is contained in:
Ross
2026-07-04 22:49:11 +01:00
parent d8bacfefa9
commit 277322059c
4 changed files with 12 additions and 2 deletions
+2 -1
View File
@@ -52,10 +52,11 @@ class LongAnswerForm(ModelForm):
class MarkLongQuestionSingleForm(ModelForm):
class Meta:
model = UserAnswer
fields = ["score", "candidate_feedback"]
fields = ["score", "candidate_feedback", "marker_feedback"]
widgets = {
"candidate_feedback": Textarea(attrs={"rows": 3}),
"marker_feedback": Textarea(attrs={"rows": 3}),
}
class MarkLongQuestionDoubleForm(ModelForm):
+4
View File
@@ -644,6 +644,10 @@ class UserAnswer(UserAnswerBase):
null=True, blank=True, help_text="Feedback for the candidate"
)
marker_feedback = models.TextField(
null=True, blank=True, help_text="Feedback for the marker, this is optional and will NOT be shown to the candidate."
)
# mark = models.ManyToManyField(
# "AnswerMarks", related_name="user_answer", blank=True
# )
+2 -1
View File
@@ -262,10 +262,11 @@ class QuestionFindingForm(ModelForm):
class MarkQuestionSingleForm(ModelForm):
class Meta:
model = UserAnswer
fields = ["score", "candidate_feedback"]
fields = ["score", "candidate_feedback", "marker_feedback"]
widgets = {
"candidate_feedback": Textarea(attrs={"rows": 3}),
"marker_feedback": Textarea(attrs={"rows": 3}),
}
class MarkQuestionDoubleForm(ModelForm):
+4
View File
@@ -624,6 +624,10 @@ class UserAnswer(UserAnswerBase):
null=True, blank=True, help_text="Feedback for the candidate, this is optional but WILL be shown to the candidate."
)
marker_feedback = models.TextField(
null=True, blank=True, help_text="Feedback for the marker, this is optional and will NOT be shown to the candidate."
)
class CallStateOptions(models.TextChoices):
CORRECT = "C", _("Correct Call")
OVERCALL = "O", _("Overcall")