|
|
|
|
@@ -17,6 +17,7 @@ import com.njcn.system.enums.DicDataEnum;
|
|
|
|
|
import com.njcn.system.enums.DicDataTypeEnum;
|
|
|
|
|
import com.njcn.system.pojo.po.DictData;
|
|
|
|
|
import lombok.RequiredArgsConstructor;
|
|
|
|
|
import org.apache.commons.collections4.CollectionUtils;
|
|
|
|
|
import org.apache.commons.collections4.ListUtils;
|
|
|
|
|
import org.springframework.stereotype.Service;
|
|
|
|
|
|
|
|
|
|
@@ -80,14 +81,20 @@ public class PwEventMonitorReportServiceImpl implements PwEventMonitorReportServ
|
|
|
|
|
|
|
|
|
|
//查询暂态事件明细
|
|
|
|
|
List<RmpEventDetailPO> detailList = new ArrayList<>();
|
|
|
|
|
List<List<String>> partition = ListUtils.partition(monitorIdList, 20000);
|
|
|
|
|
for (List<String> list : partition) {
|
|
|
|
|
if (BizParamConstant.STAT_BIZ_MONTH.equals(type + "")) { //按月查
|
|
|
|
|
detailList.addAll(rmpEventDetailMapper.getDetailsOfTransientEventsByMonth(list, null, startTime, endTime));
|
|
|
|
|
// List<List<String>> partition = ListUtils.partition(monitorIdList, 20000);
|
|
|
|
|
// for (List<String> list : partition) {
|
|
|
|
|
// if (BizParamConstant.STAT_BIZ_MONTH.equals(type + "")) { //按月查
|
|
|
|
|
// detailList.addAll(rmpEventDetailMapper.getDetailsOfTransientEventsByMonth(list, null, startTime, endTime));
|
|
|
|
|
// } else { //按日查
|
|
|
|
|
// detailList.addAll( rmpEventDetailMapper.getDetailsOfTransientEvents(list, null, startTime, endTime));
|
|
|
|
|
// }
|
|
|
|
|
// }
|
|
|
|
|
if (BizParamConstant.STAT_BIZ_MONTH.equals(type + "")) { //按月查
|
|
|
|
|
detailList.addAll(rmpEventDetailMapper.getDetailsOfTransientEventsByMonth( null, startTime, endTime));
|
|
|
|
|
} else { //按日查
|
|
|
|
|
detailList.addAll( rmpEventDetailMapper.getDetailsOfTransientEvents(list, null, startTime, endTime));
|
|
|
|
|
detailList.addAll( rmpEventDetailMapper.getDetailsOfTransientEvents(null, startTime, endTime));
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
detailList = detailList.stream().filter(temp->monitorIdList.contains(temp.getLineId())).collect(Collectors.toList());
|
|
|
|
|
if (CollUtil.isNotEmpty(detailList)) {
|
|
|
|
|
//todo 获取监测点信息接口
|
|
|
|
|
pwPmsMonitorParam.setMonitorName(eventMonitorReportParam.getMonitorName());
|
|
|
|
|
@@ -173,8 +180,10 @@ public class PwEventMonitorReportServiceImpl implements PwEventMonitorReportServ
|
|
|
|
|
condMap.put("endTime", endTime);
|
|
|
|
|
condMap.put("eventTypeList", Arrays.asList(eventStatisMapByCode.get(DicDataEnum.VOLTAGE_DIP.getCode()).getId(), eventStatisMapByCode.get(DicDataEnum.SHORT_INTERRUPTIONS.getCode()).getId()));
|
|
|
|
|
condMap.put("dateType", type);
|
|
|
|
|
EventDipShortDistributionVO eventDipShortDistribution = eventDistributionStatisticsMapper.getEventDipShortDistributionByCond(condMap);
|
|
|
|
|
|
|
|
|
|
// EventDipShortDistributionVO eventDipShortDistribution = eventDistributionStatisticsMapper.getEventDipShortDistributionByCond(condMap);
|
|
|
|
|
List<RmpEventDetailPO> eventDipShortDistributionByCondition = eventDistributionStatisticsMapper.getEventDipShortDistributionByCondition(condMap);
|
|
|
|
|
eventDipShortDistributionByCondition = eventDipShortDistributionByCondition.stream().filter(temp->monitorIds.contains(temp.getMeasurementPointId())).collect(Collectors.toList());
|
|
|
|
|
EventDipShortDistributionVO eventDipShortDistribution = change(eventDipShortDistributionByCondition);
|
|
|
|
|
//设置返回数据
|
|
|
|
|
List<EventDipShortDistributionTableVO> list = new ArrayList<>();
|
|
|
|
|
//特征幅值[80,90]
|
|
|
|
|
@@ -296,12 +305,100 @@ public class PwEventMonitorReportServiceImpl implements PwEventMonitorReportServ
|
|
|
|
|
return list;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/***
|
|
|
|
|
private EventDipShortDistributionVO change(List<RmpEventDetailPO> list) {
|
|
|
|
|
EventDipShortDistributionVO eventDipShortDistributionVO = new EventDipShortDistributionVO();
|
|
|
|
|
if(!CollectionUtils.isEmpty(list)) {
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp90with100ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 80 && temp.getFeatureAmplitude() <= 90 && temp.getDuration() > 10 && temp.getDuration() <= 100).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp90with250ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 80 && temp.getFeatureAmplitude() <= 90 && temp.getDuration() > 100 && temp.getDuration() <= 250).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp90with500ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 80 && temp.getFeatureAmplitude() <= 90 && temp.getDuration() > 250 && temp.getDuration() <= 500).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp90with1000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 80 && temp.getFeatureAmplitude() <= 90 && temp.getDuration() > 500 && temp.getDuration() <= 1000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp90with3000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 80 && temp.getFeatureAmplitude() <= 90 && temp.getDuration() > 1000 && temp.getDuration() <= 3000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp90with10000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 80 && temp.getFeatureAmplitude() <= 90 && temp.getDuration() > 3000 && temp.getDuration() <= 10000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp90with20000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 80 && temp.getFeatureAmplitude() <= 90 && temp.getDuration() > 10000 && temp.getDuration() <= 20000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp90with60000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 80 && temp.getFeatureAmplitude() <= 90 && temp.getDuration() > 20000 && temp.getDuration() <= 60000).count());
|
|
|
|
|
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp80with100ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 70 && temp.getFeatureAmplitude() <= 80 && temp.getDuration() > 10 && temp.getDuration() <= 100).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp80with250ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 70 && temp.getFeatureAmplitude() <= 80 && temp.getDuration() > 100 && temp.getDuration() <= 250).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp80with500ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 70 && temp.getFeatureAmplitude() <= 80 && temp.getDuration() > 250 && temp.getDuration() <= 500).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp80with1000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 70 && temp.getFeatureAmplitude() <= 80 && temp.getDuration() > 500 && temp.getDuration() <= 1000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp80with3000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 70 && temp.getFeatureAmplitude() <= 80 && temp.getDuration() > 1000 && temp.getDuration() <= 3000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp80with10000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 70 && temp.getFeatureAmplitude() <= 80 && temp.getDuration() > 3000 && temp.getDuration() <= 10000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp80with20000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 70 && temp.getFeatureAmplitude() <= 80 && temp.getDuration() > 10000 && temp.getDuration() <= 20000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp80with60000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 70 && temp.getFeatureAmplitude() <= 80 && temp.getDuration() > 20000 && temp.getDuration() <= 60000).count());
|
|
|
|
|
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp70with100ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 60 && temp.getFeatureAmplitude() <= 70 && temp.getDuration() > 10 && temp.getDuration() <= 100).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp70with250ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 60 && temp.getFeatureAmplitude() <= 70 && temp.getDuration() > 100 && temp.getDuration() <= 250).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp70with500ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 60 && temp.getFeatureAmplitude() <= 70 && temp.getDuration() > 250 && temp.getDuration() <= 500).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp70with1000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 60 && temp.getFeatureAmplitude() <= 70 && temp.getDuration() > 500 && temp.getDuration() <= 1000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp70with3000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 60 && temp.getFeatureAmplitude() <= 70 && temp.getDuration() > 1000 && temp.getDuration() <= 3000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp70with10000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 60 && temp.getFeatureAmplitude() <= 70 && temp.getDuration() > 3000 && temp.getDuration() <= 10000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp70with20000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 60 && temp.getFeatureAmplitude() <= 70 && temp.getDuration() > 10000 && temp.getDuration() <= 20000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp70with60000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 60 && temp.getFeatureAmplitude() <= 70 && temp.getDuration() > 20000 && temp.getDuration() <= 60000).count());
|
|
|
|
|
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp60with100ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 50 && temp.getFeatureAmplitude() <= 60 && temp.getDuration() > 10 && temp.getDuration() <= 100).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp60with250ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 50 && temp.getFeatureAmplitude() <= 60 && temp.getDuration() > 100 && temp.getDuration() <= 250).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp60with500ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 50 && temp.getFeatureAmplitude() <= 60 && temp.getDuration() > 250 && temp.getDuration() <= 500).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp60with1000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 50 && temp.getFeatureAmplitude() <= 60 && temp.getDuration() > 500 && temp.getDuration() <= 1000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp60with3000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 50 && temp.getFeatureAmplitude() <= 60 && temp.getDuration() > 1000 && temp.getDuration() <= 3000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp60with10000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 50 && temp.getFeatureAmplitude() <= 60 && temp.getDuration() > 3000 && temp.getDuration() <= 10000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp60with20000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 50 && temp.getFeatureAmplitude() <= 60 && temp.getDuration() > 10000 && temp.getDuration() <= 20000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp60with60000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 50 && temp.getFeatureAmplitude() <= 60 && temp.getDuration() > 20000 && temp.getDuration() <= 60000).count());
|
|
|
|
|
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp50with100ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 40 && temp.getFeatureAmplitude() <= 50 && temp.getDuration() > 10 && temp.getDuration() <= 100).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp50with250ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 40 && temp.getFeatureAmplitude() <= 50 && temp.getDuration() > 100 && temp.getDuration() <= 250).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp50with500ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 40 && temp.getFeatureAmplitude() <= 50 && temp.getDuration() > 250 && temp.getDuration() <= 500).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp50with1000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 40 && temp.getFeatureAmplitude() <= 50 && temp.getDuration() > 500 && temp.getDuration() <= 1000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp50with3000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 40 && temp.getFeatureAmplitude() <= 50 && temp.getDuration() > 1000 && temp.getDuration() <= 3000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp50with10000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 40 && temp.getFeatureAmplitude() <= 50 && temp.getDuration() > 3000 && temp.getDuration() <= 10000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp50with20000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 40 && temp.getFeatureAmplitude() <= 50 && temp.getDuration() > 10000 && temp.getDuration() <= 20000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp50with60000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 40 && temp.getFeatureAmplitude() <= 50 && temp.getDuration() > 20000 && temp.getDuration() <= 60000).count());
|
|
|
|
|
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp40with100ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 30 && temp.getFeatureAmplitude() <= 40 && temp.getDuration() > 10 && temp.getDuration() <= 100).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp40with250ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 30 && temp.getFeatureAmplitude() <= 40 && temp.getDuration() > 100 && temp.getDuration() <= 250).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp40with500ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 30 && temp.getFeatureAmplitude() <= 40 && temp.getDuration() > 250 && temp.getDuration() <= 500).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp40with1000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 30 && temp.getFeatureAmplitude() <= 40 && temp.getDuration() > 500 && temp.getDuration() <= 1000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp40with3000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 30 && temp.getFeatureAmplitude() <= 40 && temp.getDuration() > 1000 && temp.getDuration() <= 3000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp40with10000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 30 && temp.getFeatureAmplitude() <= 40 && temp.getDuration() > 3000 && temp.getDuration() <= 10000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp40with20000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 30 && temp.getFeatureAmplitude() <= 40 && temp.getDuration() > 10000 && temp.getDuration() <= 20000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp40with60000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 30 && temp.getFeatureAmplitude() <= 40 && temp.getDuration() > 20000 && temp.getDuration() <= 60000).count());
|
|
|
|
|
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp30with100ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 20 && temp.getFeatureAmplitude() <= 30 && temp.getDuration() > 10 && temp.getDuration() <= 100).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp30with250ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 20 && temp.getFeatureAmplitude() <= 30 && temp.getDuration() > 100 && temp.getDuration() <= 250).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp30with500ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 20 && temp.getFeatureAmplitude() <= 30 && temp.getDuration() > 250 && temp.getDuration() <= 500).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp30with1000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 20 && temp.getFeatureAmplitude() <= 30 && temp.getDuration() > 500 && temp.getDuration() <= 1000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp30with3000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 20 && temp.getFeatureAmplitude() <= 30 && temp.getDuration() > 1000 && temp.getDuration() <= 3000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp30with10000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 20 && temp.getFeatureAmplitude() <= 30 && temp.getDuration() > 3000 && temp.getDuration() <= 10000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp30with20000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 20 && temp.getFeatureAmplitude() <= 30 && temp.getDuration() > 10000 && temp.getDuration() <= 20000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp30with60000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 20 && temp.getFeatureAmplitude() <= 30 && temp.getDuration() > 20000 && temp.getDuration() <= 60000).count());
|
|
|
|
|
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp20with100ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 10 && temp.getFeatureAmplitude() <= 20 && temp.getDuration() > 10 && temp.getDuration() <= 100).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp20with250ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 10 && temp.getFeatureAmplitude() <= 20 && temp.getDuration() > 100 && temp.getDuration() <= 250).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp20with500ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 10 && temp.getFeatureAmplitude() <= 20 && temp.getDuration() > 250 && temp.getDuration() <= 500).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp20with1000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 10 && temp.getFeatureAmplitude() <= 20 && temp.getDuration() > 500 && temp.getDuration() <= 1000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp20with3000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 10 && temp.getFeatureAmplitude() <= 20 && temp.getDuration() > 1000 && temp.getDuration() <= 3000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp20with10000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 10 && temp.getFeatureAmplitude() <= 20 && temp.getDuration() > 3000 && temp.getDuration() <= 10000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp20with20000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 10 && temp.getFeatureAmplitude() <= 20 && temp.getDuration() > 10000 && temp.getDuration() <= 20000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp20with60000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 10 && temp.getFeatureAmplitude() <= 20 && temp.getDuration() > 20000 && temp.getDuration() <= 60000).count());
|
|
|
|
|
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp10with100ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 0 && temp.getFeatureAmplitude() <= 10 && temp.getDuration() > 10 && temp.getDuration() <= 100).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp10with250ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 0 && temp.getFeatureAmplitude() <= 10 && temp.getDuration() > 100 && temp.getDuration() <= 250).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp10with500ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 0 && temp.getFeatureAmplitude() <= 10 && temp.getDuration() > 250 && temp.getDuration() <= 500).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp10with1000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 0 && temp.getFeatureAmplitude() <= 10 && temp.getDuration() > 500 && temp.getDuration() <= 1000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp10with3000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 0 && temp.getFeatureAmplitude() <= 10 && temp.getDuration() > 1000 && temp.getDuration() <= 3000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp10with10000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 0 && temp.getFeatureAmplitude() <= 10 && temp.getDuration() > 3000 && temp.getDuration() <= 10000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp10with20000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 0 && temp.getFeatureAmplitude() <= 10 && temp.getDuration() > 10000 && temp.getDuration() <= 20000).count());
|
|
|
|
|
eventDipShortDistributionVO.setFeatureAmp10with60000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 0 && temp.getFeatureAmplitude() <= 10 && temp.getDuration() > 20000 && temp.getDuration() <= 60000).count());
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return eventDipShortDistributionVO;
|
|
|
|
|
}
|
|
|
|
|
/**
|
|
|
|
|
* 暂态指标监测点电压暂升分布情况
|
|
|
|
|
* @author jianghaifei
|
|
|
|
|
* @date 2022-10-29 14:08
|
|
|
|
|
* @date 2022-10-29 14:03
|
|
|
|
|
* @param eventMonitorReportParam
|
|
|
|
|
* @return com.njcn.event.pojo.vo.EventRiseDistributionVO
|
|
|
|
|
* @retu4n com.njcn.event4pojo.vo.EventRiseDistributionVO
|
|
|
|
|
*/
|
|
|
|
|
@Override
|
|
|
|
|
public List<EventRiseDistributionTableVO> getEventRiseDistributionByCond(EventMonitorReportParam eventMonitorReportParam) {
|
|
|
|
|
@@ -325,7 +422,10 @@ public class PwEventMonitorReportServiceImpl implements PwEventMonitorReportServ
|
|
|
|
|
riseCondMap.put("endTime", endTime);
|
|
|
|
|
riseCondMap.put("eventTypeList", Collections.singletonList(eventStatisMapByCode.get(DicDataEnum.VOLTAGE_RISE.getCode()).getId()));
|
|
|
|
|
riseCondMap.put("dateType", type);
|
|
|
|
|
EventRiseDistributionVO eventRiseDistribution = eventDistributionStatisticsMapper.getEventRiseDistributionByCond(riseCondMap);
|
|
|
|
|
// EventRiseDistributionVO eventRiseDistribution = eventDistributionStatisticsMapper.getEventRiseDistributionByCond(riseCondMap);
|
|
|
|
|
List<RmpEventDetailPO> rmpEventDetailPOS = eventDistributionStatisticsMapper.getEventDipShortDistributionByCondition(riseCondMap);
|
|
|
|
|
rmpEventDetailPOS = rmpEventDetailPOS.stream().filter(temp->monitorIds.contains(temp.getMeasurementPointId())).collect(Collectors.toList());
|
|
|
|
|
EventRiseDistributionVO eventRiseDistribution = changeEventRise(rmpEventDetailPOS);
|
|
|
|
|
//设置返回数据
|
|
|
|
|
List<EventRiseDistributionTableVO> list = new ArrayList<>();
|
|
|
|
|
//特征幅值U1≥120
|
|
|
|
|
@@ -345,4 +445,19 @@ public class PwEventMonitorReportServiceImpl implements PwEventMonitorReportServ
|
|
|
|
|
list.add(entity110);
|
|
|
|
|
return list;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private EventRiseDistributionVO changeEventRise(List<RmpEventDetailPO> list) {
|
|
|
|
|
EventRiseDistributionVO eventRiseDistributionVO = new EventRiseDistributionVO();
|
|
|
|
|
if(!CollectionUtils.isEmpty(list)){
|
|
|
|
|
eventRiseDistributionVO.setFeatureAmp120with500ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 120 && temp.getDuration() > 10 && temp.getDuration() <= 500).count());
|
|
|
|
|
eventRiseDistributionVO.setFeatureAmp120with5000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 120 && temp.getDuration() > 500 && temp.getDuration() <= 5000).count());
|
|
|
|
|
eventRiseDistributionVO.setFeatureAmp120with60000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= 120 && temp.getDuration() > 5000 && temp.getDuration() <= 60000).count());
|
|
|
|
|
eventRiseDistributionVO.setFeatureAmp110with500ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= -120 && temp.getFeatureAmplitude() <= 110 && temp.getDuration() > 500 && temp.getDuration() <= 60000).count());
|
|
|
|
|
eventRiseDistributionVO.setFeatureAmp110with5000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= -120 && temp.getFeatureAmplitude() <= 110 && temp.getDuration() > 5000 && temp.getDuration() <= 60000).count());
|
|
|
|
|
eventRiseDistributionVO.setFeatureAmp110with60000ms((int) list.stream().filter(temp -> temp.getFeatureAmplitude() >= -120 && temp.getFeatureAmplitude() <= 110 && temp.getDuration() > 60000 && temp.getDuration() <= 60000).count());
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
return eventRiseDistributionVO;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|