| | |
| | | import com.mes.sysconfig.entity.request.SysConfigRequest; |
| | | import com.mes.sysconfig.mapper.SysConfigMapper; |
| | | import com.mes.sysconfig.service.SysConfigService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.cache.annotation.CacheEvict; |
| | | import org.springframework.cache.annotation.CachePut; |
| | | import org.springframework.cache.annotation.Cacheable; |
| | |
| | | * @since 2025-04-01 15:01:27 |
| | | */ |
| | | @Service |
| | | @Slf4j |
| | | public class SysConfigServiceImpl extends ServiceImpl<SysConfigMapper, SysConfig> implements SysConfigService { |
| | | |
| | | @Override |
| | |
| | | public Boolean deleteConfig(Serializable id) { |
| | | return this.removeById(id); |
| | | } |
| | | |
| | | @Override |
| | | public String queryConfigValue(Serializable id) { |
| | | SysConfig sysConfig = this.queryConfigById(id); |
| | | if (sysConfig == null) { |
| | | log.info("系统配置查询为空,请检查该配置是否存在:{}", id); |
| | | return null; |
| | | } |
| | | return sysConfig.getConfigValue(); |
| | | } |
| | | } |
| | | |