diff --git a/hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/PublicController.java b/hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/PublicController.java index 433d998..b81650e 100644 --- a/hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/PublicController.java +++ b/hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/PublicController.java @@ -11,6 +11,7 @@ import com.hxhq.business.form.study.StudySearchForm; import com.hxhq.business.service.IStudyFormPreService; import com.hxhq.business.service.IStudyService; import com.hxhq.business.service.ITemplateService; +import com.hxhq.common.core.exception.ServiceException; import com.hxhq.common.core.web.controller.BaseController; import com.hxhq.common.core.web.domain.AjaxResult; import com.hxhq.common.core.web.page.TableDataInfo; @@ -57,7 +58,7 @@ public class PublicController extends BaseController public AjaxResult studyList() { QueryWrapper queryWrapper = Wrappers.query(); - queryWrapper.eq("status", StudyStatusEnum.dgd.getValue()); +// queryWrapper.eq("status", StudyStatusEnum.dgd.getValue()); todo return AjaxResult.success(studyService.list(queryWrapper)); } @@ -67,6 +68,9 @@ public class PublicController extends BaseController @GetMapping("/studyFormPreList") public AjaxResult studyFormPreList(StudyFormPre studyFormPre) { + if(studyFormPre.getStudyId()==null||studyFormPre.getStudyId().longValue()<0){ + throw new ServiceException("试验id不能为空"); + } QueryWrapper queryWrapper = Wrappers.query(); queryWrapper.eq("study_id", studyFormPre.getStudyId()); return AjaxResult.success(studyFormPreService.list(queryWrapper));