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 a787f3d..83b6f6a 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 @@ -151,16 +151,6 @@ public class PublicController extends BaseController { } - /** - * 查询试验预填表单列表 - */ - @GetMapping("/studyFormPreList") - public AjaxResult studyFormPreList(StudyFormPreSearchForm form) { - if (form.getStudyId() == null || form.getStudyId().longValue() < 0) { - throw new ServiceException("试验id不能为空"); - } - return AjaxResult.success(studyFormPreService.queryList(form)); - } /** * 查询暂存柜列表 diff --git a/hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/StudyFormPreController.java b/hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/StudyFormPreController.java index cdd4002..98738f5 100644 --- a/hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/StudyFormPreController.java +++ b/hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/StudyFormPreController.java @@ -3,14 +3,20 @@ package com.hxhq.business.controller; import java.util.Arrays; import java.util.List; +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.baomidou.mybatisplus.core.toolkit.Wrappers; import com.hxhq.business.domain.*; import com.hxhq.business.dto.study.StudyFormPreListDto; +import com.hxhq.business.enums.study.StudyStatusEnum; import com.hxhq.business.form.study.StudyFormPreAuditForm; import com.hxhq.business.form.study.StudyFormPreSearchForm; import com.hxhq.business.form.study.StudyFormUpdateForm; import com.hxhq.business.service.IStudyFormPreJcgjService; import com.hxhq.business.service.IStudyFormPreQmxxService; +import com.hxhq.business.service.IStudyService; +import com.hxhq.common.core.exception.ServiceException; import com.hxhq.common.security.annotation.RequiresPermissions; +import org.aspectj.weaver.loadtime.Aj; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.*; @@ -36,6 +42,36 @@ public class StudyFormPreController extends BaseController private IStudyFormPreJcgjService studyFormPreJcgjService; @Autowired private IStudyFormPreQmxxService studyFormPreQmxxService; + @Autowired + private IStudyService studyService; + + /** + * 查询试验列表 + */ + @GetMapping("/studyList") + @RequiresPermissions({"business:studyFormPre:bj","business:studyFormPre:xz", + "business:nonTrialFormPre:bj","business:nonTrialFormPre:xz", + "business:drugFormPre:bj","business:drugFormPre:xz"}) + public AjaxResult studyList(Study study) { + QueryWrapper queryWrapper = Wrappers.query(); + queryWrapper.ne("status", StudyStatusEnum.dgd.getValue()); + return AjaxResult.success(studyService.list(queryWrapper)); + } + + + /** + * 查询试验预填表单列表 + */ + @GetMapping("/studyFormPreList") + @RequiresPermissions({"business:studyFormPre:bj","business:studyFormPre:xz", + "business:nonTrialFormPre:bj","business:nonTrialFormPre:xz", + "business:drugFormPre:bj","business:drugFormPre:xz"}) + public AjaxResult studyFormPreList(StudyFormPreSearchForm form) { + if (form.getStudyId() == null || form.getStudyId().longValue() < 0) { + throw new ServiceException("试验id不能为空"); + } + return AjaxResult.success(studyFormPreService.queryList(form)); + } /** * 列表