|
|
@@ -5028,7 +5028,7 @@ public class QuestionServiceImpl extends ServiceImpl<QuestionMapper, Question> i
|
|
|
examQuestion.setQuestionId(questionId);
|
|
|
//获取最新排序
|
|
|
Integer sort = 0;
|
|
|
- ExamQuestion one = iExamQuestionService.getOne(new LambdaUpdateWrapper<ExamQuestion>().eq(ExamQuestion::getExamId, examId).orderByDesc(ExamQuestion::getSort));
|
|
|
+ ExamQuestion one = iExamQuestionService.getOne(new LambdaUpdateWrapper<ExamQuestion>().eq(ExamQuestion::getExamId, examId).orderByDesc(ExamQuestion::getSort).last("limit 1"));
|
|
|
if (ObjectUtils.isNotNull(one)){
|
|
|
sort = one.getSort() +1;
|
|
|
}
|