add imutable ids to some exam arrays to detect and log changes between two exams.

This commit is contained in:
Joao Correia
2025-03-02 00:10:57 +00:00
parent 4e3cfec9e8
commit 32cd8495d6
12 changed files with 309 additions and 225 deletions

View File

@@ -59,8 +59,8 @@ const reorderWriteBlanks = (exercise: WriteBlanksExercise, startId: number): Reo
let newIds = oldIds.map((_, index) => (startId + index).toString());
let newSolutions = exercise.solutions.map((solution, index) => ({
id: newIds[index],
solution: [...solution.solution]
...solution,
id: newIds[index]
}));
let newText = exercise.text;