xiangpei
2024-06-28 d0ebd33f5e4fdbff1f58a1af137d45b405366399
src/main/java/com/ycl/jxkg/service/impl/ExamServiceImpl.java
@@ -19,6 +19,7 @@
import com.ycl.jxkg.domain.question.QuestionObject;
import com.ycl.jxkg.domain.vo.*;
import com.ycl.jxkg.enums.ExamPaperTypeEnum;
import com.ycl.jxkg.enums.QuestionTypeEnum;
import com.ycl.jxkg.enums.WebsocketCommendEnum;
import com.ycl.jxkg.enums.general.ExamStatusEnum;
import com.ycl.jxkg.enums.general.ExamSubmitTempStatusEnum;
@@ -260,6 +261,12 @@
                DoQuestionVO doQuestionVO = new DoQuestionVO();
                doQuestionVO.setTitle(question.getTitle());
                doQuestionVO.setQuestionType(item.getQuestionType());
                // 填空题需要抹除content(因为是答案)
                if (QuestionTypeEnum.GapFilling.getCode().equals(doQuestionVO.getQuestionType())) {
                    question.getItems().stream().forEach(option -> {
                        option.setContent("");
                    });
                }
                doQuestionVO.setQuestionItemList(question.getItems());
                doQuestionVO.setId(question.getId());
                doQuestionVO.setOriginalFile(question.getOriginalFile());