|
@@ -495,15 +495,17 @@ public class MarkGroupController extends BaseExamController {
|
|
|
picConfigList = JSONArray.toList(array, new PictureConfigItem(), new JsonConfig());
|
|
|
}
|
|
|
if (questionIds != null && questionIds.length > 0) {
|
|
|
- group = new MarkGroup(examId, subjectCode, number, picConfigList, 0d, doubleRate,
|
|
|
- arbitrateThreshold, scorePolicy, markMode, trialCount, sheetView, enableAllZero,
|
|
|
- thirdPolicy);
|
|
|
List<ExamQuestion> list = new ArrayList<ExamQuestion>();
|
|
|
+ double totalScore = 0d;
|
|
|
for (Integer questionId : questionIds) {
|
|
|
ExamQuestion question = questionService.findById(questionId);
|
|
|
question.setGroupNumber(number);
|
|
|
list.add(question);
|
|
|
+ totalScore = totalScore + question.getTotalScore();
|
|
|
}
|
|
|
+ group = new MarkGroup(examId, subjectCode, number, picConfigList, totalScore, doubleRate,
|
|
|
+ arbitrateThreshold, scorePolicy, markMode, trialCount, sheetView, enableAllZero,
|
|
|
+ thirdPolicy);
|
|
|
// clear and replace exam_question
|
|
|
questionService.save(list);
|
|
|
groupService.save(group);
|