|
@@ -200,7 +200,7 @@ public class LeanEventWarnInfoServiceImpl extends ServiceImpl<LeanEventWarnInfoM
|
|
|
private void saveOrUpdateLeanEventWarnInfo(FpgGatherData fpgGatherData, LeanEventWarnInfo leanEventWarnInfo) {
|
|
|
LambdaQueryWrapper<LeanEventWarnInfo> wrapper = new LambdaQueryWrapper<>();
|
|
|
wrapper.eq(LeanEventWarnInfo::getDeviceRegionId, fpgGatherData.getDeviceRegionId()).eq(LeanEventWarnInfo::getDevicePointId, fpgGatherData.getDevicePointId()).
|
|
|
- eq(LeanEventWarnInfo::getDeviceInformationId, fpgGatherData.getDeviceInformationId());
|
|
|
+ eq(LeanEventWarnInfo::getDeviceInformationId, fpgGatherData.getDeviceInformationId()).eq(LeanEventWarnInfo::getWarnType, leanEventWarnInfo.getWarnType());
|
|
|
LeanEventWarnInfo leanEventWarnInfoObj = baseMapper.selectOne(wrapper);
|
|
|
if (leanEventWarnInfoObj == null){
|
|
|
baseMapper.insert(leanEventWarnInfo);
|
|
@@ -317,6 +317,7 @@ public class LeanEventWarnInfoServiceImpl extends ServiceImpl<LeanEventWarnInfoM
|
|
|
log.info("{}{}", "fpg_ing_time峰平谷数据采集FpgStatiscsModelMongodb查询为空!", "设备ID:" +fpgGatherData.getDeviceInformationId() + "采集点ID:" + fpgGatherData.getDevicePointId()+ "区域ID:" + fpgGatherData.getDevicePointId());
|
|
|
return;
|
|
|
}
|
|
|
+
|
|
|
// 判断MongoDB中的累加运行时长是否大于 LeanEventsHostConfig中的尖峰平谷运行限制时长
|
|
|
int runTimeLimit = Integer.parseInt(leanEventsHostConfig.getRunTime());
|
|
|
if("tops".equals(leanEventsHost.getDeviceInformationId())){
|