电价配置-增加站点id

This commit is contained in:
2025-10-11 16:31:32 +08:00
parent b79f9caa2d
commit 83f8f4e293

View File

@ -775,10 +775,10 @@ public class FXXDataProcessServiceImpl extends AbstractBatteryDataProcessor impl
private void dealAmmeterDailyDate(Map<String, Object> obj, String deviceId, Date dataUpdateTime) {
// 先获取当月电价配置redis没有这查数据库都没有则返回
String priceKey = RedisKeyConstants.ENERGY_PRICE_TIME + LocalDate.now().getYear() + LocalDate.now().getMonthValue();
String priceKey = RedisKeyConstants.ENERGY_PRICE_TIME + SITE_ID + "_" + LocalDate.now().getYear() + LocalDate.now().getMonthValue();
List<EnergyPriceTimeRange> timeRanges = redisCache.getCacheObject(priceKey);
if (timeRanges == null) {
timeRanges = emsEnergyPriceConfigMapper.getTimeRangeByDate(LocalDate.now().getYear(),LocalDate.now().getMonthValue());
timeRanges = emsEnergyPriceConfigMapper.getTimeRangeByDate(SITE_ID, LocalDate.now().getYear(),LocalDate.now().getMonthValue());
if (timeRanges == null) {
return;
}