zbj//1.获取电压暂态表及密度坐标图与表数据对应不上 bug修改
This commit is contained in:
@@ -157,7 +157,7 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
//查询监测点未处理暂态事件
|
//查询监测点未处理暂态事件
|
||||||
List<RmpEventDetailPO> info = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
List<RmpEventDetailPO> info = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
||||||
.eq(RmpEventDetailPO::getMeasurementPointId, statisticsParam.getLineIndex())
|
.eq(RmpEventDetailPO::getMeasurementPointId, statisticsParam.getLineIndex())
|
||||||
.ge(StringUtils.isNotBlank(statisticsParam.getStartTime()), RmpEventDetailPO::getStartTime,DateUtil.beginOfDay(DateUtil.parse(statisticsParam.getStartTime())))
|
.ge(StringUtils.isNotBlank(statisticsParam.getStartTime()), RmpEventDetailPO::getStartTime, DateUtil.beginOfDay(DateUtil.parse(statisticsParam.getStartTime())))
|
||||||
.le(StringUtils.isNotBlank(statisticsParam.getEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(statisticsParam.getEndTime())))
|
.le(StringUtils.isNotBlank(statisticsParam.getEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(statisticsParam.getEndTime())))
|
||||||
);
|
);
|
||||||
|
|
||||||
@@ -170,203 +170,203 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
Integer index = null;
|
Integer index = null;
|
||||||
CoordsVO dto = new CoordsVO();
|
CoordsVO dto = new CoordsVO();
|
||||||
if (info.get(i).getFeatureAmplitude() >= 0 && info.get(i).getFeatureAmplitude() <= 0.1) {
|
if (info.get(i).getFeatureAmplitude() >= 0 && info.get(i).getFeatureAmplitude() <= 0.1) {
|
||||||
if (info.get(i).getDuration()/1000 > 0 && info.get(i).getDuration()/1000 <= 0.020) {
|
if (info.get(i).getDuration() / 1000 > 0 && info.get(i).getDuration() / 1000 <= 0.020) {
|
||||||
index = 0;
|
index = 0;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.040 && info.get(i).getDuration()/1000 > 0.020) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.040 && info.get(i).getDuration() / 1000 > 0.020) {
|
||||||
index = 1;
|
index = 1;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.060 && info.get(i).getDuration()/1000 > 0.040) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.060 && info.get(i).getDuration() / 1000 > 0.040) {
|
||||||
index = 2;
|
index = 2;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.080 && info.get(i).getDuration()/1000 > 0.060) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.080 && info.get(i).getDuration() / 1000 > 0.060) {
|
||||||
index = 3;
|
index = 3;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.120 && info.get(i).getDuration()/1000 > 0.080) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.120 && info.get(i).getDuration() / 1000 > 0.080) {
|
||||||
index = 4;
|
index = 4;
|
||||||
} else if (info.get(i).getDuration()/1000 > 0.120 && info.get(i).getDuration()/1000 < 0.200) {
|
} else if (info.get(i).getDuration() / 1000 > 0.120 && info.get(i).getDuration() / 1000 < 0.200) {
|
||||||
index = 5;
|
index = 5;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.200 && info.get(i).getDuration()/1000 < 0.400) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.200 && info.get(i).getDuration() / 1000 < 0.400) {
|
||||||
index = 6;
|
index = 6;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.400 && info.get(i).getDuration()/1000 < 0.600) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.400 && info.get(i).getDuration() / 1000 < 0.600) {
|
||||||
index = 7;
|
index = 7;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.600 && info.get(i).getDuration()/1000 <= 1.200) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.600 && info.get(i).getDuration() / 1000 <= 1.200) {
|
||||||
index = 8;
|
index = 8;
|
||||||
}
|
}
|
||||||
} else if (info.get(i).getFeatureAmplitude() > 0.1 && info.get(i).getFeatureAmplitude() <= 0.2) {
|
} else if (info.get(i).getFeatureAmplitude() > 0.1 && info.get(i).getFeatureAmplitude() <= 0.2) {
|
||||||
if (info.get(i).getDuration()/1000 > 0 && info.get(i).getDuration()/1000 <= 0.020) {
|
if (info.get(i).getDuration() / 1000 > 0 && info.get(i).getDuration() / 1000 <= 0.020) {
|
||||||
index = 9;
|
index = 9;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.040 && info.get(i).getDuration()/1000 > 0.020) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.040 && info.get(i).getDuration() / 1000 > 0.020) {
|
||||||
index = 10;
|
index = 10;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.060 && info.get(i).getDuration()/1000 > 0.040) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.060 && info.get(i).getDuration() / 1000 > 0.040) {
|
||||||
index = 11;
|
index = 11;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.080 && info.get(i).getDuration()/1000 > 0.060) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.080 && info.get(i).getDuration() / 1000 > 0.060) {
|
||||||
index = 12;
|
index = 12;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.120 && info.get(i).getDuration()/1000 > 0.080) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.120 && info.get(i).getDuration() / 1000 > 0.080) {
|
||||||
index = 13;
|
index = 13;
|
||||||
} else if (info.get(i).getDuration()/1000 > 0.120 && info.get(i).getDuration()/1000 < 0.200) {
|
} else if (info.get(i).getDuration() / 1000 > 0.120 && info.get(i).getDuration() / 1000 < 0.200) {
|
||||||
index = 14;
|
index = 14;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.200 && info.get(i).getDuration()/1000 < 0.400) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.200 && info.get(i).getDuration() / 1000 < 0.400) {
|
||||||
index = 15;
|
index = 15;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.400 && info.get(i).getDuration()/1000 < 0.600) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.400 && info.get(i).getDuration() / 1000 < 0.600) {
|
||||||
index = 16;
|
index = 16;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.600 && info.get(i).getDuration()/1000 <= 1.200) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.600 && info.get(i).getDuration() / 1000 <= 1.200) {
|
||||||
index = 17;
|
index = 17;
|
||||||
}
|
}
|
||||||
} else if (info.get(i).getFeatureAmplitude() > 0.2 && info.get(i).getFeatureAmplitude() <= 0.3) {
|
} else if (info.get(i).getFeatureAmplitude() > 0.2 && info.get(i).getFeatureAmplitude() <= 0.3) {
|
||||||
if (info.get(i).getDuration()/1000 > 0 && info.get(i).getDuration()/1000 <= 0.020) {
|
if (info.get(i).getDuration() / 1000 > 0 && info.get(i).getDuration() / 1000 <= 0.020) {
|
||||||
index = 18;
|
index = 18;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.040 && info.get(i).getDuration()/1000 > 0.020) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.040 && info.get(i).getDuration() / 1000 > 0.020) {
|
||||||
index = 19;
|
index = 19;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.060 && info.get(i).getDuration()/1000 > 0.040) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.060 && info.get(i).getDuration() / 1000 > 0.040) {
|
||||||
index = 20;
|
index = 20;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.080 && info.get(i).getDuration()/1000 > 0.060) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.080 && info.get(i).getDuration() / 1000 > 0.060) {
|
||||||
index = 21;
|
index = 21;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.120 && info.get(i).getDuration()/1000 > 0.080) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.120 && info.get(i).getDuration() / 1000 > 0.080) {
|
||||||
index = 22;
|
index = 22;
|
||||||
} else if (info.get(i).getDuration()/1000 > 0.120 && info.get(i).getDuration()/1000 < 0.200) {
|
} else if (info.get(i).getDuration() / 1000 > 0.120 && info.get(i).getDuration() / 1000 < 0.200) {
|
||||||
index = 23;
|
index = 23;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.200 && info.get(i).getDuration()/1000 < 0.400) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.200 && info.get(i).getDuration() / 1000 < 0.400) {
|
||||||
index = 24;
|
index = 24;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.400 && info.get(i).getDuration()/1000 < 0.600) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.400 && info.get(i).getDuration() / 1000 < 0.600) {
|
||||||
index = 25;
|
index = 25;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.600 && info.get(i).getDuration()/1000 <= 1.200) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.600 && info.get(i).getDuration() / 1000 <= 1.200) {
|
||||||
index = 26;
|
index = 26;
|
||||||
}
|
}
|
||||||
} else if (info.get(i).getFeatureAmplitude() > 0.3 && info.get(i).getFeatureAmplitude() <= 0.4) {
|
} else if (info.get(i).getFeatureAmplitude() > 0.3 && info.get(i).getFeatureAmplitude() <= 0.4) {
|
||||||
if (info.get(i).getDuration()/1000 > 0 && info.get(i).getDuration()/1000 <= 0.020) {
|
if (info.get(i).getDuration() / 1000 > 0 && info.get(i).getDuration() / 1000 <= 0.020) {
|
||||||
index = 27;
|
index = 27;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.040 && info.get(i).getDuration()/1000 > 0.020) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.040 && info.get(i).getDuration() / 1000 > 0.020) {
|
||||||
index = 28;
|
index = 28;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.060 && info.get(i).getDuration()/1000 > 0.040) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.060 && info.get(i).getDuration() / 1000 > 0.040) {
|
||||||
index = 29;
|
index = 29;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.080 && info.get(i).getDuration()/1000 > 0.060) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.080 && info.get(i).getDuration() / 1000 > 0.060) {
|
||||||
index = 30;
|
index = 30;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.120 && info.get(i).getDuration()/1000 > 0.080) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.120 && info.get(i).getDuration() / 1000 > 0.080) {
|
||||||
index = 31;
|
index = 31;
|
||||||
} else if (info.get(i).getDuration()/1000 > 0.120 && info.get(i).getDuration()/1000 < 0.200) {
|
} else if (info.get(i).getDuration() / 1000 > 0.120 && info.get(i).getDuration() / 1000 < 0.200) {
|
||||||
index = 32;
|
index = 32;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.200 && info.get(i).getDuration()/1000 < 0.400) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.200 && info.get(i).getDuration() / 1000 < 0.400) {
|
||||||
index = 33;
|
index = 33;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.400 && info.get(i).getDuration()/1000 < 0.600) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.400 && info.get(i).getDuration() / 1000 < 0.600) {
|
||||||
index = 34;
|
index = 34;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.600 && info.get(i).getDuration()/1000 <= 1.200) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.600 && info.get(i).getDuration() / 1000 <= 1.200) {
|
||||||
index = 35;
|
index = 35;
|
||||||
}
|
}
|
||||||
} else if (info.get(i).getFeatureAmplitude() > 0.4 && info.get(i).getFeatureAmplitude() <= 0.5) {
|
} else if (info.get(i).getFeatureAmplitude() > 0.4 && info.get(i).getFeatureAmplitude() <= 0.5) {
|
||||||
if (info.get(i).getDuration()/1000 > 0 && info.get(i).getDuration()/1000 <= 0.020) {
|
if (info.get(i).getDuration() / 1000 > 0 && info.get(i).getDuration() / 1000 <= 0.020) {
|
||||||
index = 36;
|
index = 36;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.040 && info.get(i).getDuration()/1000 > 0.020) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.040 && info.get(i).getDuration() / 1000 > 0.020) {
|
||||||
index = 37;
|
index = 37;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.060 && info.get(i).getDuration()/1000 > 0.040) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.060 && info.get(i).getDuration() / 1000 > 0.040) {
|
||||||
index = 38;
|
index = 38;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.080 && info.get(i).getDuration()/1000 > 0.060) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.080 && info.get(i).getDuration() / 1000 > 0.060) {
|
||||||
index = 39;
|
index = 39;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.120 && info.get(i).getDuration()/1000 > 0.080) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.120 && info.get(i).getDuration() / 1000 > 0.080) {
|
||||||
index = 40;
|
index = 40;
|
||||||
} else if (info.get(i).getDuration()/1000 > 0.120 && info.get(i).getDuration()/1000 < 0.200) {
|
} else if (info.get(i).getDuration() / 1000 > 0.120 && info.get(i).getDuration() / 1000 < 0.200) {
|
||||||
index = 41;
|
index = 41;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.200 && info.get(i).getDuration()/1000 < 0.400) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.200 && info.get(i).getDuration() / 1000 < 0.400) {
|
||||||
index = 42;
|
index = 42;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.400 && info.get(i).getDuration()/1000 < 0.600) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.400 && info.get(i).getDuration() / 1000 < 0.600) {
|
||||||
index = 43;
|
index = 43;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.600 && info.get(i).getDuration()/1000 <= 1.200) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.600 && info.get(i).getDuration() / 1000 <= 1.200) {
|
||||||
index = 44;
|
index = 44;
|
||||||
}
|
}
|
||||||
} else if (info.get(i).getFeatureAmplitude() > 0.5 && info.get(i).getFeatureAmplitude() <= 0.6) {
|
} else if (info.get(i).getFeatureAmplitude() > 0.5 && info.get(i).getFeatureAmplitude() <= 0.6) {
|
||||||
if (info.get(i).getDuration()/1000 > 0 && info.get(i).getDuration()/1000 <= 0.020) {
|
if (info.get(i).getDuration() / 1000 > 0 && info.get(i).getDuration() / 1000 <= 0.020) {
|
||||||
index = 45;
|
index = 45;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.040 && info.get(i).getDuration()/1000 > 0.020) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.040 && info.get(i).getDuration() / 1000 > 0.020) {
|
||||||
index = 46;
|
index = 46;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.060 && info.get(i).getDuration()/1000 > 0.040) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.060 && info.get(i).getDuration() / 1000 > 0.040) {
|
||||||
index = 47;
|
index = 47;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.080 && info.get(i).getDuration()/1000 > 0.060) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.080 && info.get(i).getDuration() / 1000 > 0.060) {
|
||||||
index = 48;
|
index = 48;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.120 && info.get(i).getDuration()/1000 > 0.080) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.120 && info.get(i).getDuration() / 1000 > 0.080) {
|
||||||
index = 49;
|
index = 49;
|
||||||
} else if (info.get(i).getDuration()/1000 > 0.120 && info.get(i).getDuration()/1000 < 0.200) {
|
} else if (info.get(i).getDuration() / 1000 > 0.120 && info.get(i).getDuration() / 1000 < 0.200) {
|
||||||
index = 50;
|
index = 50;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.200 && info.get(i).getDuration()/1000 < 0.400) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.200 && info.get(i).getDuration() / 1000 < 0.400) {
|
||||||
index = 51;
|
index = 51;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.400 && info.get(i).getDuration()/1000 < 0.600) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.400 && info.get(i).getDuration() / 1000 < 0.600) {
|
||||||
index = 52;
|
index = 52;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.600 && info.get(i).getDuration()/1000 <= 1.200) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.600 && info.get(i).getDuration() / 1000 <= 1.200) {
|
||||||
index = 53;
|
index = 53;
|
||||||
}
|
}
|
||||||
} else if (info.get(i).getFeatureAmplitude() > 0.6 && info.get(i).getFeatureAmplitude() <= 0.7) {
|
} else if (info.get(i).getFeatureAmplitude() > 0.6 && info.get(i).getFeatureAmplitude() <= 0.7) {
|
||||||
if (info.get(i).getDuration()/1000 > 0 && info.get(i).getDuration()/1000 <= 0.020) {
|
if (info.get(i).getDuration() / 1000 > 0 && info.get(i).getDuration() / 1000 <= 0.020) {
|
||||||
index = 54;
|
index = 54;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.040 && info.get(i).getDuration()/1000 > 0.020) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.040 && info.get(i).getDuration() / 1000 > 0.020) {
|
||||||
index = 55;
|
index = 55;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.060 && info.get(i).getDuration()/1000 > 0.040) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.060 && info.get(i).getDuration() / 1000 > 0.040) {
|
||||||
index = 56;
|
index = 56;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.080 && info.get(i).getDuration()/1000 > 0.060) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.080 && info.get(i).getDuration() / 1000 > 0.060) {
|
||||||
index = 57;
|
index = 57;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.120 && info.get(i).getDuration()/1000 > 0.080) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.120 && info.get(i).getDuration() / 1000 > 0.080) {
|
||||||
index = 58;
|
index = 58;
|
||||||
} else if (info.get(i).getDuration()/1000 > 0.120 && info.get(i).getDuration()/1000 < 0.200) {
|
} else if (info.get(i).getDuration() / 1000 > 0.120 && info.get(i).getDuration() / 1000 < 0.200) {
|
||||||
index = 59;
|
index = 59;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.200 && info.get(i).getDuration()/1000 < 0.400) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.200 && info.get(i).getDuration() / 1000 < 0.400) {
|
||||||
index = 60;
|
index = 60;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.400 && info.get(i).getDuration()/1000 < 0.600) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.400 && info.get(i).getDuration() / 1000 < 0.600) {
|
||||||
index = 61;
|
index = 61;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.600 && info.get(i).getDuration()/1000 <= 1.200) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.600 && info.get(i).getDuration() / 1000 <= 1.200) {
|
||||||
index = 62;
|
index = 62;
|
||||||
}
|
}
|
||||||
} else if (info.get(i).getFeatureAmplitude() > 0.7 && info.get(i).getFeatureAmplitude() <= 0.8) {
|
} else if (info.get(i).getFeatureAmplitude() > 0.7 && info.get(i).getFeatureAmplitude() <= 0.8) {
|
||||||
if (info.get(i).getDuration()/1000 > 0 && info.get(i).getDuration()/1000 <= 0.020) {
|
if (info.get(i).getDuration() / 1000 > 0 && info.get(i).getDuration() / 1000 <= 0.020) {
|
||||||
index = 63;
|
index = 63;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.040 && info.get(i).getDuration()/1000 > 0.020) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.040 && info.get(i).getDuration() / 1000 > 0.020) {
|
||||||
index = 64;
|
index = 64;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.060 && info.get(i).getDuration()/1000 > 0.040) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.060 && info.get(i).getDuration() / 1000 > 0.040) {
|
||||||
index = 65;
|
index = 65;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.080 && info.get(i).getDuration()/1000 > 0.060) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.080 && info.get(i).getDuration() / 1000 > 0.060) {
|
||||||
index = 66;
|
index = 66;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.120 && info.get(i).getDuration()/1000 > 0.080) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.120 && info.get(i).getDuration() / 1000 > 0.080) {
|
||||||
index = 67;
|
index = 67;
|
||||||
} else if (info.get(i).getDuration()/1000 > 0.120 && info.get(i).getDuration()/1000 < 0.200) {
|
} else if (info.get(i).getDuration() / 1000 > 0.120 && info.get(i).getDuration() / 1000 < 0.200) {
|
||||||
index = 68;
|
index = 68;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.200 && info.get(i).getDuration()/1000 < 0.400) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.200 && info.get(i).getDuration() / 1000 < 0.400) {
|
||||||
index = 69;
|
index = 69;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.400 && info.get(i).getDuration()/1000 < 0.600) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.400 && info.get(i).getDuration() / 1000 < 0.600) {
|
||||||
index = 70;
|
index = 70;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.600 && info.get(i).getDuration()/1000 <= 1.200) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.600 && info.get(i).getDuration() / 1000 <= 1.200) {
|
||||||
index = 71;
|
index = 71;
|
||||||
}
|
}
|
||||||
} else if (info.get(i).getFeatureAmplitude() > 0.8 && info.get(i).getFeatureAmplitude() <= 0.9) {
|
} else if (info.get(i).getFeatureAmplitude() > 0.8 && info.get(i).getFeatureAmplitude() <= 0.9) {
|
||||||
if (info.get(i).getDuration()/1000 > 0 && info.get(i).getDuration()/1000 <= 0.020) {
|
if (info.get(i).getDuration() / 1000 > 0 && info.get(i).getDuration() / 1000 <= 0.020) {
|
||||||
index = 72;
|
index = 72;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.040 && info.get(i).getDuration()/1000 > 0.020) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.040 && info.get(i).getDuration() / 1000 > 0.020) {
|
||||||
index = 73;
|
index = 73;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.060 && info.get(i).getDuration()/1000 > 0.040) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.060 && info.get(i).getDuration() / 1000 > 0.040) {
|
||||||
index = 74;
|
index = 74;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.080 && info.get(i).getDuration()/1000 > 0.060) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.080 && info.get(i).getDuration() / 1000 > 0.060) {
|
||||||
index = 75;
|
index = 75;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.120 && info.get(i).getDuration()/1000 > 0.080) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.120 && info.get(i).getDuration() / 1000 > 0.080) {
|
||||||
index = 76;
|
index = 76;
|
||||||
} else if (info.get(i).getDuration()/1000 > 0.120 && info.get(i).getDuration()/1000 < 0.200) {
|
} else if (info.get(i).getDuration() / 1000 > 0.120 && info.get(i).getDuration() / 1000 < 0.200) {
|
||||||
index = 77;
|
index = 77;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.200 && info.get(i).getDuration()/1000 < 0.400) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.200 && info.get(i).getDuration() / 1000 < 0.400) {
|
||||||
index = 78;
|
index = 78;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.400 && info.get(i).getDuration()/1000 < 0.600) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.400 && info.get(i).getDuration() / 1000 < 0.600) {
|
||||||
index = 79;
|
index = 79;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.600 && info.get(i).getDuration()/1000 <= 1.200) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.600 && info.get(i).getDuration() / 1000 <= 1.200) {
|
||||||
index = 80;
|
index = 80;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (info.get(i).getDuration()/1000 > 0 && info.get(i).getDuration()/1000 <= 0.020) {
|
if (info.get(i).getDuration() / 1000 > 0 && info.get(i).getDuration() / 1000 <= 0.020) {
|
||||||
index = 81;
|
index = 81;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.040 && info.get(i).getDuration()/1000 > 0.020) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.040 && info.get(i).getDuration() / 1000 > 0.020) {
|
||||||
index = 82;
|
index = 82;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.060 && info.get(i).getDuration()/1000 > 0.040) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.060 && info.get(i).getDuration() / 1000 > 0.040) {
|
||||||
index = 83;
|
index = 83;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.080 && info.get(i).getDuration()/1000 > 0.060) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.080 && info.get(i).getDuration() / 1000 > 0.060) {
|
||||||
index = 84;
|
index = 84;
|
||||||
} else if (info.get(i).getDuration()/1000 <= 0.120 && info.get(i).getDuration()/1000 > 0.080) {
|
} else if (info.get(i).getDuration() / 1000 <= 0.120 && info.get(i).getDuration() / 1000 > 0.080) {
|
||||||
index = 85;
|
index = 85;
|
||||||
} else if (info.get(i).getDuration()/1000 > 0.120 && info.get(i).getDuration()/1000 < 0.200) {
|
} else if (info.get(i).getDuration() / 1000 > 0.120 && info.get(i).getDuration() / 1000 < 0.200) {
|
||||||
index = 86;
|
index = 86;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.200 && info.get(i).getDuration()/1000 < 0.400) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.200 && info.get(i).getDuration() / 1000 < 0.400) {
|
||||||
index = 87;
|
index = 87;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.400 && info.get(i).getDuration()/1000 < 0.600) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.400 && info.get(i).getDuration() / 1000 < 0.600) {
|
||||||
index = 88;
|
index = 88;
|
||||||
} else if (info.get(i).getDuration()/1000 >= 0.600 && info.get(i).getDuration()/1000 <= 1.200) {
|
} else if (info.get(i).getDuration() / 1000 >= 0.600 && info.get(i).getDuration() / 1000 <= 1.200) {
|
||||||
index = 89;
|
index = 89;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -381,10 +381,19 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
@Override
|
@Override
|
||||||
public List<DISDIPVO> eventDisdip(StatisticsParam statisticsParam) {
|
public List<DISDIPVO> eventDisdip(StatisticsParam statisticsParam) {
|
||||||
List<DISDIPVO> result = new ArrayList<>();
|
List<DISDIPVO> result = new ArrayList<>();
|
||||||
List<EventDetail> info = new ArrayList<>();
|
|
||||||
|
/*List<EventDetail> info = new ArrayList<>();
|
||||||
QueryResult query = MonitorQuery(statisticsParam);
|
QueryResult query = MonitorQuery(statisticsParam);
|
||||||
InfluxDBResultMapper influxDBResultMapper = new InfluxDBResultMapper();
|
InfluxDBResultMapper influxDBResultMapper = new InfluxDBResultMapper();
|
||||||
info = influxDBResultMapper.toPOJO(query, EventDetail.class);
|
info = influxDBResultMapper.toPOJO(query, EventDetail.class);*/
|
||||||
|
|
||||||
|
//查询监测点未处理暂态事件
|
||||||
|
List<RmpEventDetailPO> info = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
||||||
|
.eq(RmpEventDetailPO::getMeasurementPointId, statisticsParam.getLineIndex())
|
||||||
|
.ge(StringUtils.isNotBlank(statisticsParam.getStartTime()), RmpEventDetailPO::getStartTime,DateUtil.beginOfDay(DateUtil.parse(statisticsParam.getStartTime())))
|
||||||
|
.le(StringUtils.isNotBlank(statisticsParam.getEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(statisticsParam.getEndTime())))
|
||||||
|
);
|
||||||
|
|
||||||
int[][] arr = new int[5][8];
|
int[][] arr = new int[5][8];
|
||||||
for (int i = 0; i < 5; i++) {
|
for (int i = 0; i < 5; i++) {
|
||||||
for (int j = 0; j < 8; j++) {
|
for (int j = 0; j < 8; j++) {
|
||||||
@@ -505,7 +514,7 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
//查询监测点未处理暂态事件
|
//查询监测点未处理暂态事件
|
||||||
List<RmpEventDetailPO> info = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
List<RmpEventDetailPO> info = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
||||||
.eq(RmpEventDetailPO::getMeasurementPointId, statisticsParam.getLineIndex())
|
.eq(RmpEventDetailPO::getMeasurementPointId, statisticsParam.getLineIndex())
|
||||||
.ge(StringUtils.isNotBlank(statisticsParam.getStartTime()), RmpEventDetailPO::getStartTime,DateUtil.beginOfDay(DateUtil.parse(statisticsParam.getStartTime())))
|
.ge(StringUtils.isNotBlank(statisticsParam.getStartTime()), RmpEventDetailPO::getStartTime, DateUtil.beginOfDay(DateUtil.parse(statisticsParam.getStartTime())))
|
||||||
.le(StringUtils.isNotBlank(statisticsParam.getEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(statisticsParam.getEndTime())))
|
.le(StringUtils.isNotBlank(statisticsParam.getEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(statisticsParam.getEndTime())))
|
||||||
);
|
);
|
||||||
int[][] arr = new int[3][6];
|
int[][] arr = new int[3][6];
|
||||||
@@ -569,10 +578,20 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<IEC28VO> IEC28(StatisticsParam statisticsParam) {
|
public List<IEC28VO> IEC28(StatisticsParam statisticsParam) {
|
||||||
|
|
||||||
List<IEC28VO> result = new ArrayList<>();
|
List<IEC28VO> result = new ArrayList<>();
|
||||||
QueryResult query = MonitorQuery(statisticsParam);
|
|
||||||
|
/*QueryResult query = MonitorQuery(statisticsParam);
|
||||||
InfluxDBResultMapper influxDBResultMapper = new InfluxDBResultMapper();
|
InfluxDBResultMapper influxDBResultMapper = new InfluxDBResultMapper();
|
||||||
List<EventDetail> info = influxDBResultMapper.toPOJO(query, EventDetail.class);
|
List<EventDetail> info = influxDBResultMapper.toPOJO(query, EventDetail.class);*/
|
||||||
|
|
||||||
|
//查询监测点未处理暂态事件
|
||||||
|
List<RmpEventDetailPO> info = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
||||||
|
.eq(RmpEventDetailPO::getMeasurementPointId, statisticsParam.getLineIndex())
|
||||||
|
.ge(StringUtils.isNotBlank(statisticsParam.getStartTime()), RmpEventDetailPO::getStartTime, DateUtil.beginOfDay(DateUtil.parse(statisticsParam.getStartTime())))
|
||||||
|
.le(StringUtils.isNotBlank(statisticsParam.getEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(statisticsParam.getEndTime())))
|
||||||
|
);
|
||||||
|
|
||||||
int[][] arr = new int[17][8];
|
int[][] arr = new int[17][8];
|
||||||
for (int i = 0; i < 17; i++) {
|
for (int i = 0; i < 17; i++) {
|
||||||
for (int j = 0; j < 8; j++) {
|
for (int j = 0; j < 8; j++) {
|
||||||
@@ -935,7 +954,7 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
Integer endMonth = Integer.parseInt(endTime.substring(5, 7));
|
Integer endMonth = Integer.parseInt(endTime.substring(5, 7));
|
||||||
Integer startYear = Integer.parseInt(startTime.substring(0, 4));
|
Integer startYear = Integer.parseInt(startTime.substring(0, 4));
|
||||||
Integer endYear = Integer.parseInt(endTime.substring(0, 4));
|
Integer endYear = Integer.parseInt(endTime.substring(0, 4));
|
||||||
if (statisticsParam.getFlag()==0){
|
if (statisticsParam.getFlag() == 0) {
|
||||||
while (startYear != endYear && startMonth != endMonth) {
|
while (startYear != endYear && startMonth != endMonth) {
|
||||||
builder1.delete(0, builder1.length());
|
builder1.delete(0, builder1.length());
|
||||||
builder2.delete(0, builder2.length());
|
builder2.delete(0, builder2.length());
|
||||||
@@ -952,14 +971,14 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
// long count = eventDetailList.stream().filter(x -> x.getWaveType() == 1).count();
|
// long count = eventDetailList.stream().filter(x -> x.getWaveType() == 1).count();
|
||||||
List<RmpEventDetailPO> eventDetailList = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
List<RmpEventDetailPO> eventDetailList = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
||||||
.eq(RmpEventDetailPO::getMeasurementPointId, statisticsParam.getLineIndex())
|
.eq(RmpEventDetailPO::getMeasurementPointId, statisticsParam.getLineIndex())
|
||||||
.ge(StringUtils.isNotBlank(statisticsParam.getStartTime()), RmpEventDetailPO::getStartTime,DateUtil.beginOfDay(DateUtil.parse(statisticsParam.getStartTime())))
|
.ge(StringUtils.isNotBlank(statisticsParam.getStartTime()), RmpEventDetailPO::getStartTime, DateUtil.beginOfDay(DateUtil.parse(statisticsParam.getStartTime())))
|
||||||
.le(StringUtils.isNotBlank(statisticsParam.getEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(statisticsParam.getEndTime())))
|
.le(StringUtils.isNotBlank(statisticsParam.getEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(statisticsParam.getEndTime())))
|
||||||
);
|
);
|
||||||
long count = eventDetailList.stream().filter(x -> data.getId().equals(x.getEventType())).count();
|
long count = eventDetailList.stream().filter(x -> data.getId().equals(x.getEventType())).count();
|
||||||
if (startMonth < 10) {
|
if (startMonth < 10) {
|
||||||
list.add(new TimeVO(null, null,"", "0" + startMonth.toString(), count+"", startYear.toString(), startYear.toString()+"-"+"0"+startMonth.toString()));
|
list.add(new TimeVO(null, null, "", "0" + startMonth.toString(), count + "", startYear.toString(), startYear.toString() + "-" + "0" + startMonth.toString()));
|
||||||
} else {
|
} else {
|
||||||
list.add(new TimeVO(null, null,"", startMonth.toString(), count+"", startYear.toString(),startYear.toString()+"-"+startMonth.toString()));
|
list.add(new TimeVO(null, null, "", startMonth.toString(), count + "", startYear.toString(), startYear.toString() + "-" + startMonth.toString()));
|
||||||
}
|
}
|
||||||
startMonth++;
|
startMonth++;
|
||||||
if (startMonth == 13) {
|
if (startMonth == 13) {
|
||||||
@@ -977,18 +996,17 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
// long count1 = eventDetailList.stream().filter(x -> x.getWaveType() == 1).count();
|
// long count1 = eventDetailList.stream().filter(x -> x.getWaveType() == 1).count();
|
||||||
List<RmpEventDetailPO> eventDetailList = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
List<RmpEventDetailPO> eventDetailList = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
||||||
.eq(RmpEventDetailPO::getMeasurementPointId, statisticsParam.getLineIndex())
|
.eq(RmpEventDetailPO::getMeasurementPointId, statisticsParam.getLineIndex())
|
||||||
.ge(StringUtils.isNotBlank(statisticsParam.getStartTime()), RmpEventDetailPO::getStartTime,DateUtil.beginOfDay(DateUtil.parse(statisticsParam.getStartTime())))
|
.ge(StringUtils.isNotBlank(statisticsParam.getStartTime()), RmpEventDetailPO::getStartTime, DateUtil.beginOfDay(DateUtil.parse(statisticsParam.getStartTime())))
|
||||||
.le(StringUtils.isNotBlank(statisticsParam.getEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(statisticsParam.getEndTime())))
|
.le(StringUtils.isNotBlank(statisticsParam.getEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(statisticsParam.getEndTime())))
|
||||||
);
|
);
|
||||||
long count1 = eventDetailList.stream().filter(x -> data.getId().equals(x.getEventType())).count();
|
long count1 = eventDetailList.stream().filter(x -> data.getId().equals(x.getEventType())).count();
|
||||||
if (startMonth < 10) {
|
if (startMonth < 10) {
|
||||||
list.add(new TimeVO(null, null,"", "0" + startMonth.toString(), count1+"", startYear.toString(), startYear.toString()+"-"+"0"+startMonth.toString()));
|
list.add(new TimeVO(null, null, "", "0" + startMonth.toString(), count1 + "", startYear.toString(), startYear.toString() + "-" + "0" + startMonth.toString()));
|
||||||
} else {
|
} else {
|
||||||
list.add(new TimeVO(null, null,"", startMonth.toString(), count1+"", startYear.toString(),startYear.toString()+"-"+startMonth.toString()));
|
list.add(new TimeVO(null, null, "", startMonth.toString(), count1 + "", startYear.toString(), startYear.toString() + "-" + startMonth.toString()));
|
||||||
}
|
}
|
||||||
return list;
|
return list;
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
// QueryResult monitorQuery = MonitorQuery(statisticsParam);
|
// QueryResult monitorQuery = MonitorQuery(statisticsParam);
|
||||||
// InfluxDBResultMapper influxDBResultMapper = new InfluxDBResultMapper();
|
// InfluxDBResultMapper influxDBResultMapper = new InfluxDBResultMapper();
|
||||||
// List<EventDetailNew> eventDetailList = influxDBResultMapper.toPOJO(monitorQuery, EventDetailNew.class);
|
// List<EventDetailNew> eventDetailList = influxDBResultMapper.toPOJO(monitorQuery, EventDetailNew.class);
|
||||||
@@ -996,7 +1014,7 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
|
|
||||||
List<RmpEventDetailPO> eventDetailList = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
List<RmpEventDetailPO> eventDetailList = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
||||||
.eq(RmpEventDetailPO::getMeasurementPointId, statisticsParam.getLineIndex())
|
.eq(RmpEventDetailPO::getMeasurementPointId, statisticsParam.getLineIndex())
|
||||||
.ge(StringUtils.isNotBlank(statisticsParam.getStartTime()), RmpEventDetailPO::getStartTime,DateUtil.beginOfDay(DateUtil.parse(statisticsParam.getStartTime())))
|
.ge(StringUtils.isNotBlank(statisticsParam.getStartTime()), RmpEventDetailPO::getStartTime, DateUtil.beginOfDay(DateUtil.parse(statisticsParam.getStartTime())))
|
||||||
.le(StringUtils.isNotBlank(statisticsParam.getEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(statisticsParam.getEndTime())))
|
.le(StringUtils.isNotBlank(statisticsParam.getEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(statisticsParam.getEndTime())))
|
||||||
);
|
);
|
||||||
|
|
||||||
@@ -1006,43 +1024,43 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
|
|
||||||
LocalDate parse1 = LocalDate.parse(startTime);
|
LocalDate parse1 = LocalDate.parse(startTime);
|
||||||
LocalDate parse2 = LocalDate.parse(endTime);
|
LocalDate parse2 = LocalDate.parse(endTime);
|
||||||
while (!parse1.equals(parse2.plus(1, ChronoUnit.DAYS))){
|
while (!parse1.equals(parse2.plus(1, ChronoUnit.DAYS))) {
|
||||||
if (keySet.contains(parse1.toString())){
|
if (keySet.contains(parse1.toString())) {
|
||||||
// List<EventDetailNew> eventDetailNews = map.get(parse1.toString());
|
// List<EventDetailNew> eventDetailNews = map.get(parse1.toString());
|
||||||
List<RmpEventDetailPO> eventDetailNews = map.get(parse1.toString());
|
List<RmpEventDetailPO> eventDetailNews = map.get(parse1.toString());
|
||||||
TimeVO timeVO = new TimeVO();
|
TimeVO timeVO = new TimeVO();
|
||||||
timeVO.setTimes(eventDetailNews.size()+"");
|
timeVO.setTimes(eventDetailNews.size() + "");
|
||||||
if (parse1.getDayOfMonth()<10){
|
if (parse1.getDayOfMonth() < 10) {
|
||||||
timeVO.setDay("0"+parse1.getDayOfMonth()+"");
|
timeVO.setDay("0" + parse1.getDayOfMonth() + "");
|
||||||
}else {
|
} else {
|
||||||
timeVO.setDay(parse1.getDayOfMonth()+"");
|
timeVO.setDay(parse1.getDayOfMonth() + "");
|
||||||
}
|
}
|
||||||
timeVO.setYear(parse1.getYear()+"");
|
timeVO.setYear(parse1.getYear() + "");
|
||||||
if (parse1.getMonthValue()<10){
|
if (parse1.getMonthValue() < 10) {
|
||||||
timeVO.setMonth("0"+parse1.getMonthValue()+"");
|
timeVO.setMonth("0" + parse1.getMonthValue() + "");
|
||||||
}else {
|
} else {
|
||||||
timeVO.setMonth(parse1.getMonthValue()+"");
|
timeVO.setMonth(parse1.getMonthValue() + "");
|
||||||
}
|
}
|
||||||
timeVO.setFulltime(parse1.toString());
|
timeVO.setFulltime(parse1.toString());
|
||||||
list.add(timeVO);
|
list.add(timeVO);
|
||||||
}else {
|
} else {
|
||||||
TimeVO timeVO = new TimeVO();
|
TimeVO timeVO = new TimeVO();
|
||||||
timeVO.setTimes("0");
|
timeVO.setTimes("0");
|
||||||
if (parse1.getDayOfMonth()<10){
|
if (parse1.getDayOfMonth() < 10) {
|
||||||
timeVO.setDay("0"+parse1.getDayOfMonth()+"");
|
timeVO.setDay("0" + parse1.getDayOfMonth() + "");
|
||||||
}else {
|
} else {
|
||||||
timeVO.setDay(parse1.getDayOfMonth()+"");
|
timeVO.setDay(parse1.getDayOfMonth() + "");
|
||||||
}
|
}
|
||||||
timeVO.setYear(parse1.getYear()+"");
|
timeVO.setYear(parse1.getYear() + "");
|
||||||
if (parse1.getMonthValue()<10){
|
if (parse1.getMonthValue() < 10) {
|
||||||
timeVO.setMonth("0"+parse1.getMonthValue()+"");
|
timeVO.setMonth("0" + parse1.getMonthValue() + "");
|
||||||
}else {
|
} else {
|
||||||
timeVO.setMonth(parse1.getMonthValue()+"");
|
timeVO.setMonth(parse1.getMonthValue() + "");
|
||||||
}
|
}
|
||||||
timeVO.setFulltime(parse1.toString());
|
timeVO.setFulltime(parse1.toString());
|
||||||
list.add(timeVO);
|
list.add(timeVO);
|
||||||
}
|
}
|
||||||
parse1=parse1.plus(1, ChronoUnit.DAYS);
|
parse1 = parse1.plus(1, ChronoUnit.DAYS);
|
||||||
}
|
}
|
||||||
return list;
|
return list;
|
||||||
}
|
}
|
||||||
@@ -1061,7 +1079,7 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
//数据暂降查询
|
//数据暂降查询
|
||||||
List<RmpEventDetailPO> info = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
List<RmpEventDetailPO> info = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
||||||
.eq(RmpEventDetailPO::getMeasurementPointId, statisticsParam.getLineIndex())
|
.eq(RmpEventDetailPO::getMeasurementPointId, statisticsParam.getLineIndex())
|
||||||
.ge(StringUtils.isNotBlank(statisticsParam.getStartTime()), RmpEventDetailPO::getStartTime,DateUtil.beginOfDay(DateUtil.parse(statisticsParam.getStartTime())))
|
.ge(StringUtils.isNotBlank(statisticsParam.getStartTime()), RmpEventDetailPO::getStartTime, DateUtil.beginOfDay(DateUtil.parse(statisticsParam.getStartTime())))
|
||||||
.le(StringUtils.isNotBlank(statisticsParam.getEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(statisticsParam.getEndTime())))
|
.le(StringUtils.isNotBlank(statisticsParam.getEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(statisticsParam.getEndTime())))
|
||||||
);
|
);
|
||||||
|
|
||||||
@@ -1078,18 +1096,18 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
//添加detail
|
//添加detail
|
||||||
for (RmpEventDetailPO detail : info) {
|
for (RmpEventDetailPO detail : info) {
|
||||||
EventDetail details = null;
|
EventDetail details = null;
|
||||||
if (dataDto.getId() .equals(detail.getEventType())) {
|
if (dataDto.getId().equals(detail.getEventType())) {
|
||||||
for (DictData data : reasonData) {
|
for (DictData data : reasonData) {
|
||||||
reasonMap.put(data.getName(),0);
|
reasonMap.put(data.getName(), 0);
|
||||||
if (detail.getAdvanceReason().equals(data.getId())) {
|
if (detail.getAdvanceReason().equals(data.getId())) {
|
||||||
details=BeanUtil.copyProperties(detail,EventDetail.class);
|
details = BeanUtil.copyProperties(detail, EventDetail.class);
|
||||||
details.setAdvanceReason(data.getName());
|
details.setAdvanceReason(data.getName());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
for (DictData data : typeData) {
|
for (DictData data : typeData) {
|
||||||
typeMap.put(data.getName(),0);
|
typeMap.put(data.getName(), 0);
|
||||||
if (detail.getAdvanceType().equals(data.getId())) {
|
if (detail.getAdvanceType().equals(data.getId())) {
|
||||||
details=BeanUtil.copyProperties(detail,EventDetail.class);
|
details = BeanUtil.copyProperties(detail, EventDetail.class);
|
||||||
detail.setAdvanceType(data.getName());
|
detail.setAdvanceType(data.getName());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1140,7 +1158,7 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
//数据暂降查询
|
//数据暂降查询
|
||||||
List<RmpEventDetailPO> infos = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
List<RmpEventDetailPO> infos = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
||||||
.eq(RmpEventDetailPO::getMeasurementPointId, statisticsParam.getLineIndex())
|
.eq(RmpEventDetailPO::getMeasurementPointId, statisticsParam.getLineIndex())
|
||||||
.ge(StringUtils.isNotBlank(statisticsParam.getStartTime()), RmpEventDetailPO::getStartTime,DateUtil.beginOfDay(DateUtil.parse(statisticsParam.getStartTime())))
|
.ge(StringUtils.isNotBlank(statisticsParam.getStartTime()), RmpEventDetailPO::getStartTime, DateUtil.beginOfDay(DateUtil.parse(statisticsParam.getStartTime())))
|
||||||
.le(StringUtils.isNotBlank(statisticsParam.getEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(statisticsParam.getEndTime())))
|
.le(StringUtils.isNotBlank(statisticsParam.getEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(statisticsParam.getEndTime())))
|
||||||
);
|
);
|
||||||
List<EventDetail> info2 = BeanUtil.copyToList(infos, EventDetail.class);
|
List<EventDetail> info2 = BeanUtil.copyToList(infos, EventDetail.class);
|
||||||
@@ -1441,7 +1459,7 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
//查询监测点未处理暂态事件
|
//查询监测点未处理暂态事件
|
||||||
List<RmpEventDetailPO> eventDetails = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
List<RmpEventDetailPO> eventDetails = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
||||||
.eq(RmpEventDetailPO::getMeasurementPointId, statisticsParam.getLineIndex())
|
.eq(RmpEventDetailPO::getMeasurementPointId, statisticsParam.getLineIndex())
|
||||||
.ge(StringUtils.isNotBlank(statisticsParam.getStartTime()), RmpEventDetailPO::getStartTime,DateUtil.beginOfDay(DateUtil.parse(statisticsParam.getStartTime())))
|
.ge(StringUtils.isNotBlank(statisticsParam.getStartTime()), RmpEventDetailPO::getStartTime, DateUtil.beginOfDay(DateUtil.parse(statisticsParam.getStartTime())))
|
||||||
.le(StringUtils.isNotBlank(statisticsParam.getEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(statisticsParam.getEndTime())))
|
.le(StringUtils.isNotBlank(statisticsParam.getEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(statisticsParam.getEndTime())))
|
||||||
);
|
);
|
||||||
//获取字典属性
|
//获取字典属性
|
||||||
@@ -1453,7 +1471,7 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
DictData data = dicDataFeignClient.getDicDataByCode(DicDataEnum.VOLTAGE_DIP.getCode()).getData();
|
DictData data = dicDataFeignClient.getDicDataByCode(DicDataEnum.VOLTAGE_DIP.getCode()).getData();
|
||||||
EventDetail eventDetailNew;
|
EventDetail eventDetailNew;
|
||||||
for (RmpEventDetailPO eventDetail : eventDetails) {
|
for (RmpEventDetailPO eventDetail : eventDetails) {
|
||||||
eventDetailNew= BeanUtil.copyProperties(eventDetail,EventDetail.class);
|
eventDetailNew = BeanUtil.copyProperties(eventDetail, EventDetail.class);
|
||||||
//监测点id
|
//监测点id
|
||||||
eventDetailNew.setLineId(eventDetail.getMeasurementPointId());
|
eventDetailNew.setLineId(eventDetail.getMeasurementPointId());
|
||||||
//持续时间
|
//持续时间
|
||||||
@@ -1462,7 +1480,7 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
eventDetailNew.setFeatureAmplitude(eventDetail.getFeatureAmplitude());
|
eventDetailNew.setFeatureAmplitude(eventDetail.getFeatureAmplitude());
|
||||||
//波形路径
|
//波形路径
|
||||||
eventDetailNew.setWavePath(eventDetail.getWavePath());
|
eventDetailNew.setWavePath(eventDetail.getWavePath());
|
||||||
if(data.getId().equals(eventDetail.getEventType())) {
|
if (data.getId().equals(eventDetail.getEventType())) {
|
||||||
if (reasonMap.containsKey(eventDetail.getAdvanceReason())) {
|
if (reasonMap.containsKey(eventDetail.getAdvanceReason())) {
|
||||||
//暂降原因
|
//暂降原因
|
||||||
DictData dictData = reasonMap.get(eventDetail.getAdvanceReason());
|
DictData dictData = reasonMap.get(eventDetail.getAdvanceReason());
|
||||||
@@ -1523,13 +1541,13 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
//数据暂降查询
|
//数据暂降查询
|
||||||
Page<RmpEventDetailPO> pageInfo = eventDetailService.page(new Page<>(eventBaseParam.getPageNum(), eventBaseParam.getPageSize()), new LambdaQueryWrapper<RmpEventDetailPO>()
|
Page<RmpEventDetailPO> pageInfo = eventDetailService.page(new Page<>(eventBaseParam.getPageNum(), eventBaseParam.getPageSize()), new LambdaQueryWrapper<RmpEventDetailPO>()
|
||||||
.eq(RmpEventDetailPO::getMeasurementPointId, eventBaseParam.getLineId())
|
.eq(RmpEventDetailPO::getMeasurementPointId, eventBaseParam.getLineId())
|
||||||
.ge(StringUtils.isNotBlank(eventBaseParam.getSearchBeginTime()), RmpEventDetailPO::getStartTime,DateUtil.beginOfDay(DateUtil.parse(eventBaseParam.getSearchBeginTime())))
|
.ge(StringUtils.isNotBlank(eventBaseParam.getSearchBeginTime()), RmpEventDetailPO::getStartTime, DateUtil.beginOfDay(DateUtil.parse(eventBaseParam.getSearchBeginTime())))
|
||||||
.le(StringUtils.isNotBlank(eventBaseParam.getSearchEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(eventBaseParam.getSearchEndTime())))
|
.le(StringUtils.isNotBlank(eventBaseParam.getSearchEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(eventBaseParam.getSearchEndTime())))
|
||||||
|
|
||||||
);
|
);
|
||||||
//获取关于监测点发电站相关信息
|
//获取关于监测点发电站相关信息
|
||||||
List<AreaLineInfoVO> areaLineList = lineFeignClient.getBaseLineAreaInfo(Arrays.asList(eventBaseParam.getLineId())).getData();
|
List<AreaLineInfoVO> areaLineList = lineFeignClient.getBaseLineAreaInfo(Arrays.asList(eventBaseParam.getLineId())).getData();
|
||||||
if(CollectionUtil.isEmpty(areaLineList)) {
|
if (CollectionUtil.isEmpty(areaLineList)) {
|
||||||
throw new BusinessException(EventResponseEnum.NOT_FOUND);
|
throw new BusinessException(EventResponseEnum.NOT_FOUND);
|
||||||
}
|
}
|
||||||
List<WaveTypeVO> waveTypeVOS = new ArrayList<>();
|
List<WaveTypeVO> waveTypeVOS = new ArrayList<>();
|
||||||
@@ -1537,7 +1555,7 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
WaveTypeVO waveTypeVO;
|
WaveTypeVO waveTypeVO;
|
||||||
//将监测点发电机相关信息copy到准备好的VO对象中
|
//将监测点发电机相关信息copy到准备好的VO对象中
|
||||||
for (RmpEventDetailPO record : records) {
|
for (RmpEventDetailPO record : records) {
|
||||||
waveTypeVO=BeanUtil.copyProperties(record,WaveTypeVO.class);
|
waveTypeVO = BeanUtil.copyProperties(record, WaveTypeVO.class);
|
||||||
if (waveTypeVO.getLineId() != null) {
|
if (waveTypeVO.getLineId() != null) {
|
||||||
for (AreaLineInfoVO lineInfoVO : areaLineList) {
|
for (AreaLineInfoVO lineInfoVO : areaLineList) {
|
||||||
if (waveTypeVO.getLineId().equals(lineInfoVO.getLineId())) {
|
if (waveTypeVO.getLineId().equals(lineInfoVO.getLineId())) {
|
||||||
@@ -1592,7 +1610,7 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
throw new BusinessException(EventResponseEnum.EVENT_NOT_FOUND);
|
throw new BusinessException(EventResponseEnum.EVENT_NOT_FOUND);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Page<WaveTypeVO> page=BeanUtil.copyProperties(pageInfo,Page.class);
|
Page<WaveTypeVO> page = BeanUtil.copyProperties(pageInfo, Page.class);
|
||||||
page.setRecords(waveTypeVOS);
|
page.setRecords(waveTypeVOS);
|
||||||
return page;
|
return page;
|
||||||
// //提前创建结果集合
|
// //提前创建结果集合
|
||||||
@@ -1837,7 +1855,6 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 监测点事件波形下载
|
* 监测点事件波形下载
|
||||||
*
|
*
|
||||||
|
|||||||
Reference in New Issue
Block a user