|
@@ -55,11 +55,11 @@ public class PaperDetailUnitService {
|
|
|
public PaperDetailUnit savePaperDetailUnit(PaperDetailUnitExp pduExp) {
|
|
|
PaperDetailUnit oldPdu = paperDetailUnitRepo.findOne(pduExp.getId());
|
|
|
if (oldPdu.getQuestionType() == QuesStructType.NESTED_ANSWER_QUESTION) {
|
|
|
+ List<Double> subScoreList = oldPdu.getSubScoreList();
|
|
|
if (pduExp.getQuestion().getId().equals(oldPdu.getQuestion().getId())) {
|
|
|
//更新对象为套题本身
|
|
|
oldPdu.setQuestion(quesService.saveQues(pduExp.getQuestion()));
|
|
|
} else {
|
|
|
- List<Double> subScoreList = oldPdu.getSubScoreList();
|
|
|
int size = oldPdu.getQuestion().getSubQuestions().size();
|
|
|
boolean match = false;
|
|
|
// 判断更新的对象是哪个子题
|
|
@@ -79,9 +79,9 @@ public class PaperDetailUnitService {
|
|
|
if (match) {
|
|
|
oldPdu.setQuestion(quesService.saveQues(oldPdu.getQuestion()));
|
|
|
}
|
|
|
- //更新套题unit当前总分
|
|
|
- oldPdu.setSubScoreList(subScoreList);
|
|
|
}
|
|
|
+ //更新套题unit当前总分与子题分数
|
|
|
+ oldPdu.setSubScoreList(subScoreList);
|
|
|
} else {
|
|
|
oldPdu.setQuestion(quesService.saveQues(pduExp.getQuestion()));
|
|
|
oldPdu.setScore(pduExp.getScore());
|