修正渗流数据公式计算的单位
parent
0ef16c7afa
commit
2466d6c469
|
|
@ -22,9 +22,9 @@ public class ScheduledTask {
|
|||
String OS = System.getProperty("os.name").toLowerCase();
|
||||
|
||||
// 简单粗暴的判断,在 linux 环境下运行时,为生成环境
|
||||
// if (OS.contains("linux")) {
|
||||
// iDeviceDataService.syncData();
|
||||
if (OS.contains("linux")) {
|
||||
iDeviceDataService.syncData();
|
||||
iDeviceSLDataService.syncData();
|
||||
// }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -15,8 +15,8 @@ import com.whdc.zhdbaqapi.service.IDeviceSLInfoService;
|
|||
import com.whdc.zhdbaqapi.utils.DataUtils;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
//import org.springframework.cache.annotation.CacheEvict;
|
||||
//import org.springframework.cache.annotation.Cacheable;
|
||||
import org.springframework.cache.annotation.CacheEvict;
|
||||
import org.springframework.cache.annotation.Cacheable;
|
||||
import org.springframework.data.redis.core.RedisTemplate;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
|
@ -56,7 +56,7 @@ public class DeviceSLInfoServiceimpl extends ServiceImpl<DeviceSLInfoMapper, Dev
|
|||
}
|
||||
|
||||
@Override
|
||||
// @CacheEvict(Constants.CACHE_NAME)
|
||||
@CacheEvict(Constants.CACHE_NAME)
|
||||
public boolean save(DeviceSLInfo entity) {
|
||||
if (baseMapper.checkValidStationCode(entity.getStationCode()) != null) {
|
||||
throw new MyException("stationCode=" + entity.getStationCode() + " 已被其他有效数据使用,不能恢复");
|
||||
|
|
@ -67,7 +67,7 @@ public class DeviceSLInfoServiceimpl extends ServiceImpl<DeviceSLInfoMapper, Dev
|
|||
}
|
||||
|
||||
@Override
|
||||
// @CacheEvict(Constants.CACHE_NAME)
|
||||
@CacheEvict(Constants.CACHE_NAME)
|
||||
public boolean updateById(DeviceSLInfo entity) {
|
||||
DeviceSLInfo old = baseMapper.checkValidStationCode(entity.getStationCode());
|
||||
if (old == null) {
|
||||
|
|
@ -94,7 +94,7 @@ public class DeviceSLInfoServiceimpl extends ServiceImpl<DeviceSLInfoMapper, Dev
|
|||
}
|
||||
|
||||
@Override
|
||||
// @CacheEvict(Constants.CACHE_NAME)
|
||||
@CacheEvict(Constants.CACHE_NAME)
|
||||
public boolean updateByIdInternal(DeviceSLInfo entity) {
|
||||
DeviceSLInfo old = baseMapper.checkValidStationCode(entity.getStationCode());
|
||||
if (old != null && !old.getId().equals(entity.getId())) {
|
||||
|
|
@ -106,7 +106,7 @@ public class DeviceSLInfoServiceimpl extends ServiceImpl<DeviceSLInfoMapper, Dev
|
|||
}
|
||||
|
||||
@Override
|
||||
// @CacheEvict(Constants.CACHE_NAME)
|
||||
@CacheEvict(Constants.CACHE_NAME)
|
||||
public boolean removeById(Serializable id) {
|
||||
DeviceSLInfo entity = baseMapper.selectById(id);
|
||||
entity.setDel(1);
|
||||
|
|
@ -114,7 +114,7 @@ public class DeviceSLInfoServiceimpl extends ServiceImpl<DeviceSLInfoMapper, Dev
|
|||
}
|
||||
|
||||
@Override
|
||||
// @CacheEvict(Constants.CACHE_NAME)
|
||||
@CacheEvict(Constants.CACHE_NAME)
|
||||
public boolean restore(Integer id) {
|
||||
DeviceSLInfo entity = baseMapper.selectById(id);
|
||||
|
||||
|
|
@ -136,7 +136,7 @@ public class DeviceSLInfoServiceimpl extends ServiceImpl<DeviceSLInfoMapper, Dev
|
|||
}
|
||||
|
||||
@Override
|
||||
// @Cacheable(Constants.CACHE_NAME)
|
||||
@Cacheable(Constants.CACHE_NAME)
|
||||
public List<DeviceSLInfo> listAll() {
|
||||
return baseMapper.listAll();
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue