diff --git a/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/template/controller/ParamsInfoEOController.java b/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/template/controller/ParamsInfoEOController.java index ab39e0243..7723c44be 100644 --- a/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/template/controller/ParamsInfoEOController.java +++ b/jero-boot/jero-boot-module-certification/src/main/java/com/jero/modules/cert/template/controller/ParamsInfoEOController.java @@ -10,6 +10,7 @@ import com.jero.common.aspect.annotation.AutoLog; import com.jero.common.constant.enums.CutEnum; import com.jero.common.system.base.controller.JeroController; import com.jero.modules.cert.template.entity.ParamsInfoEO; +import com.jero.modules.cert.template.enums.ControlTypeEnum; import com.jero.modules.cert.template.service.IParamsInfoEOService; import com.jero.modules.cert.template.service.IParamsInfoPublishEOService; import com.jero.modules.cert.template.vo.ParamsInfoVO; @@ -136,7 +137,8 @@ public class ParamsInfoEOController extends JeroController add(@Validated @RequestBody ParamsInfoEO paramsInfoEO) { - if (StringUtils.isEmpty(paramsInfoEO.getCertCategory())) { + if (StringUtils.isEmpty(paramsInfoEO.getCertCategory()) + && !ControlTypeEnum.Title.getValue().equals(paramsInfoEO.getControlType())) { return Result.error("认证类别不能为空!"); } boolean isSuccess = paramsInfoEOService.add(paramsInfoEO); @@ -158,7 +160,8 @@ public class ParamsInfoEOController extends JeroController edit(@Validated @RequestBody ParamsInfoEO paramsInfoEO) { - if (StringUtils.isEmpty(paramsInfoEO.getCertCategory())) { + if (StringUtils.isEmpty(paramsInfoEO.getCertCategory()) + && !ControlTypeEnum.Title.getValue().equals(paramsInfoEO.getControlType())) { return Result.error("认证类别不能为空!"); } boolean isSuccess = paramsInfoEOService.editById(paramsInfoEO);