Skip to content

Commit d27af45

Browse files
committed
export previous year's question with question details
1 parent 838dd49 commit d27af45

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

crowdsourcer/management/commands/export_marks.py

+6
Original file line numberDiff line numberDiff line change
@@ -171,6 +171,7 @@ def handle(
171171
"topic",
172172
"clarifications",
173173
"groups",
174+
"previous_year_question",
174175
]
175176
]
176177

@@ -187,6 +188,10 @@ def handle(
187188

188189
groups = [g.description for g in question.questiongroup.all()]
189190

191+
prev_question = ""
192+
if question.previous_question:
193+
prev_question = question.previous_question.number_and_part
194+
190195
question_data.append(
191196
[
192197
question.number_and_part,
@@ -200,6 +205,7 @@ def handle(
200205
question.topic,
201206
question.clarifications,
202207
",".join(groups),
208+
prev_question,
203209
]
204210
)
205211

0 commit comments

Comments
 (0)