Prechádzať zdrojové kódy

feature 异常提示信息

xiahan 1 rok pred
rodič
commit
3b4a19ae4e

+ 2 - 1
rw-training/training-common/src/main/java/com/rongwei/trainingcommon/sys/service/impl/ExportTrainingDemandServiceImpl.java

@@ -6,6 +6,7 @@ import com.aspose.words.net.System.Data.DataRow;
 import com.aspose.words.net.System.Data.DataTable;
 import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
 import com.rongwei.rwcommon.base.BaseDo;
+import com.rongwei.rwcommon.base.exception.CustomException;
 import com.rongwei.rwcommon.utils.StringUtils;
 import com.rongwei.training.domain.DemandSurveyUserAnswerDo;
 import com.rongwei.training.domain.TrainingDemandSurveyBackupsDo;
@@ -168,7 +169,7 @@ public class ExportTrainingDemandServiceImpl implements ExportTrainingDemandServ
         List<DemandSurveyUserAnswerDo> userAnswer = demandSurveyUserAnswerService.list(new LambdaQueryWrapper<DemandSurveyUserAnswerDo>().eq(DemandSurveyUserAnswerDo::getSurverid, backupId));
         if (userAnswer.isEmpty()) {
             log.error("参数异常");
-            throw new RuntimeException("当前调查暂无人填写问卷信息");
+            throw new CustomException("当前调查暂无人填写问卷信息");
         }
         // 对问卷答案按照填写人进行分组
         Map<String, List<DemandSurveyUserAnswerDo>> collect = userAnswer.stream().collect(Collectors.groupingBy(BaseDo::getCreateuserid));