参数不存在时 增加打印
This commit is contained in:
parent
2ef59654ef
commit
f617343a01
|
|
@ -10,6 +10,7 @@ import com.czg.system.service.SysParamsService;
|
|||
import com.czg.utils.AssertUtil;
|
||||
import com.mybatisflex.core.query.QueryWrapper;
|
||||
import com.mybatisflex.spring.service.impl.ServiceImpl;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.dubbo.config.annotation.DubboService;
|
||||
import org.springframework.cache.annotation.CacheConfig;
|
||||
import org.springframework.cache.annotation.CacheEvict;
|
||||
|
|
@ -23,6 +24,7 @@ import java.util.List;
|
|||
* @author mac
|
||||
* @since 2025-02-07
|
||||
*/
|
||||
@Slf4j
|
||||
@DubboService
|
||||
@CacheConfig(cacheNames = "params")
|
||||
public class SysParamsServiceImpl extends ServiceImpl<SysParamsMapper, SysParams> implements SysParamsService {
|
||||
|
|
@ -110,6 +112,7 @@ public class SysParamsServiceImpl extends ServiceImpl<SysParamsMapper, SysParams
|
|||
@Override
|
||||
public String getSysParamValue(String code) {
|
||||
SysParams sysParam = getSysParam(code);
|
||||
log.error("参数不存在,参数编码:{}", code);
|
||||
AssertUtil.isNull(sysParam, "参数不存在");
|
||||
AssertUtil.isBlank(sysParam.getParamValue(), "参数值为空");
|
||||
return sysParam.getParamValue();
|
||||
|
|
|
|||
Loading…
Reference in New Issue