|
@@ -4061,20 +4061,20 @@ public class JavaFunctionJobHandler extends IJobHandler {
|
|
|
//AGC
|
|
|
List<PointInfo> entityAgc = getEntity("AGC002", "booster");
|
|
|
entityAgc = entityAgc.stream().filter(e -> stId.equals(e.getStationId())).collect(Collectors.toList());
|
|
|
- Map<String, PointInfo> statMapAgc = getStatDataByEntity(entityAgc, goldenUri(), begin, end, PointInfo::getStationId);
|
|
|
+ Map<String, PointInfo> statMapAgc = getRawDataByEntity(entityAgc, goldenUri(), begin, end, PointInfo::getStationId);
|
|
|
//出线
|
|
|
List<PointInfo> entityCx = getEntity("AGC001", "booster");
|
|
|
entityCx = entityCx.stream().filter(e -> stId.equals(e.getStationId())).collect(Collectors.toList());
|
|
|
- Map<String, PointInfo> statMapCx = getStatDataByEntity(entityCx, goldenUri(), begin, end, PointInfo::getStationId);
|
|
|
+ Map<String, PointInfo> statMapCx = getRawDataByEntity(entityCx, goldenUri(), begin, end, PointInfo::getStationId);
|
|
|
//风速
|
|
|
List<PointInfo> entityFs = getEntity("AI066", "turbine");
|
|
|
entityFs = entityFs.stream().filter(e -> stId.equals(e.getStationId())).collect(Collectors.toList());
|
|
|
- getStatDataByEntity(entityFs, goldenUri(), begin, end);
|
|
|
+ getRawDataByEntity(entityFs, goldenUri(), begin, end);
|
|
|
Map<String, List<PointInfo>> fssMap = entityFs.stream().collect(Collectors.groupingBy(PointInfo::getStationId));
|
|
|
//环境温度
|
|
|
List<PointInfo> entityHjwd = getEntity("AI072", "turbine");
|
|
|
entityHjwd = entityHjwd.stream().filter(e -> stId.equals(e.getStationId())).collect(Collectors.toList());
|
|
|
- getStatDataByEntity(entityHjwd, goldenUri(), begin, end);
|
|
|
+ getRawDataByEntity(entityHjwd, goldenUri(), begin, end);
|
|
|
Map<String, List<PointInfo>> hjwdsMap = entityHjwd.stream().collect(Collectors.groupingBy(PointInfo::getStationId));
|
|
|
//日发电量
|
|
|
List<PointInfo> entity = getEntity("Z-ZXYG-JX", "meter");
|
|
@@ -4089,18 +4089,19 @@ public class JavaFunctionJobHandler extends IJobHandler {
|
|
|
PointInfo agcInfo = statMapAgc.get(id);
|
|
|
PointInfo cxInfo = statMapCx.get(id);
|
|
|
List<PointInfo> fsInfos = fssMap.get(id);
|
|
|
- double pjfs = fsInfos.stream().mapToDouble(pi -> pi.getPointDatas().get(0).getValue()).average().orElse(0);
|
|
|
+ double pjfs = fsInfos.stream().mapToDouble(pi -> pi.getPointDatas().stream().mapToDouble(PointData::getValue).average().orElse(0.0)).average().orElse(0);
|
|
|
List<PointInfo> hjwdInfos = hjwdsMap.get(id);
|
|
|
- double hjwd = hjwdInfos.stream().mapToDouble(pi -> pi.getPointDatas().get(0).getValue()).average().orElse(0);
|
|
|
+ double hjwd = hjwdInfos.stream().mapToDouble(pi -> pi.getPointDatas().stream().mapToDouble(PointData::getValue).average().orElse(0.0)).average().orElse(0);
|
|
|
List<PointInfo> fdlInfos = fdlsMap.get(id);
|
|
|
double rfdl = fdlInfos.stream().mapToDouble(pi -> {
|
|
|
double v = (pi.getPointDatas().get(1).getValue() - pi.getPointDatas().get(0).getValue()) * pi.getCoef();
|
|
|
if (v < 0 || v > 720000) v = 0;
|
|
|
return v;
|
|
|
}).sum();
|
|
|
-
|
|
|
- day.setAgc(agcInfo.getPointDatas().get(0).getValue() * agcInfo.getCoef());
|
|
|
- day.setPjgl(cxInfo.getPointDatas().get(0).getValue() * cxInfo.getCoef());
|
|
|
+ double agc = agcInfo.getPointDatas().stream().mapToDouble(PointData::getValue).average().orElse(0.0);
|
|
|
+ double cxgl = cxInfo.getPointDatas().stream().mapToDouble(PointData::getValue).average().orElse(0.0);
|
|
|
+ day.setAgc(agc * agcInfo.getCoef());
|
|
|
+ day.setPjgl(cxgl * cxInfo.getCoef());
|
|
|
day.setPjfs(pjfs);
|
|
|
day.setRfdl(rfdl);
|
|
|
day.setHjwd(hjwd);
|