heheng
2025-03-10 c0ae989839d8323974048b71f7dadc29a20a4b15
src/main/java/com/gkhy/labRiskManage/api/controller/riskReport/RiskAssessPlanController.java
@@ -14,6 +14,7 @@
import com.gkhy.labRiskManage.commons.utils.BeanCopyUtils;
import com.gkhy.labRiskManage.domain.riskReport.model.dto.AssessPlanUpdateDTO;
import com.gkhy.labRiskManage.domain.riskReport.model.dto.FactorQueryDTO;
import com.gkhy.labRiskManage.domain.riskReport.service.RiskAssessPlanService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.util.ObjectUtils;
import org.springframework.web.bind.annotation.*;
@@ -30,6 +31,9 @@
    @Autowired
    private RiskAccessAppService riskAccessAppService;
    @Autowired
    private RiskAssessPlanService riskAssessPlanService;;
    /**
     * 风险评估计划 - 插入
@@ -68,6 +72,24 @@
        result.setTotal(queryResult.getTotal());
        result.setCount(queryResult.getTotal().intValue());
        return result;
    }
    @PostMapping("/update/appoint")
    public Result appoint(@RequestBody AppointUserReBO appointUserReBO){
        Result result = new Result();
        result.setCode(ResultCode.OK);
        result.setMsg("已经重新指定专家");
        AssessPlanUpdateDTO assessPlanUpdateDTO = riskAccessAppService.appoint(getCurrentUserId(), appointUserReBO);
        if (ObjectUtils.isEmpty(assessPlanUpdateDTO)){
            result.setCode(ResultCode.NOT_OK);
            result.setMsg("重新指定专家失败");
            return result;
        }
        return result;
    }
@@ -354,15 +376,15 @@
    /**
     * 风险评估计划 - 重新指定专家
     */
    @PostMapping("/update/appoint")
    public Result appoint(@RequestBody AppointUserReBO appointUserReBO){
    @PostMapping("/update/appointNew")
    public Result appointNew(@RequestBody AppointUserTypeReBO appointUserReBO){
        Result result = new Result();
        result.setCode(ResultCode.OK);
        result.setMsg("已经重新指定专家");
        AssessPlanUpdateDTO assessPlanUpdateDTO = riskAccessAppService.appoint(getCurrentUserId(), appointUserReBO);
        if (ObjectUtils.isEmpty(assessPlanUpdateDTO)){
        int i = riskAssessPlanService.appointNew(getCurrentUserId(), appointUserReBO);
        if (i < 1){
            result.setCode(ResultCode.NOT_OK);
            result.setMsg("重新指定专家失败");
            return result;
@@ -370,6 +392,9 @@
        return result;
    }
    /**
     * 风险辨识与评价 - 查询
     */