Browse Source

预测发电量站端上传修改为计算(调控后短期)

fanxiaoyu 7 months ago
parent
commit
eaa3412063

+ 5 - 5
cpp-admin/src/main/java/com/cpp/web/service/powerGeneation/impl/DayPowerGenerationServiceImpl.java

@@ -218,12 +218,12 @@ public class DayPowerGenerationServiceImpl extends ServiceImpl<DayPowerGeneratio
     public String[] findSendData(Long stTime, Long eTime, List<? extends BaseCppEntity> list) {
         String[] datas = new String[0];
         List<ForecastPowerShortTermCloud> forecastPowerShortTermCloudList = new ArrayList<>();
-        List<ForecastPowerShortTermStation> forecastPowerShortTermStationList = new ArrayList<>();
+        List<ForecastPowerShortTermRegulation> forecastPowerShortTermStationList = new ArrayList<>();
         for (BaseCppEntity entity : list) {
             if (entity instanceof ForecastPowerShortTermCloud) {
                 forecastPowerShortTermCloudList.add((ForecastPowerShortTermCloud) entity);
-            } else if (entity instanceof ForecastPowerShortTermStation) {
-                forecastPowerShortTermStationList.add((ForecastPowerShortTermStation) entity);
+            } else if (entity instanceof ForecastPowerShortTermRegulation) {
+                forecastPowerShortTermStationList.add((ForecastPowerShortTermRegulation) entity);
             }
         }
         if (forecastPowerShortTermCloudList.size() > 0) {
@@ -237,11 +237,11 @@ public class DayPowerGenerationServiceImpl extends ServiceImpl<DayPowerGeneratio
                 }
             }
         } else {
-            List<ForecastPowerShortTermStation> collectList = forecastPowerShortTermStationList.stream().filter(s -> s.getTime().getTime() >= stTime && s.getTime().getTime() <= eTime).collect(Collectors.toList());
+            List<ForecastPowerShortTermRegulation> collectList = forecastPowerShortTermStationList.stream().filter(s -> s.getTime().getTime() >= stTime && s.getTime().getTime() <= eTime).collect(Collectors.toList());
             if (null != forecastPowerShortTermStationList && forecastPowerShortTermStationList.size() > 0) {
                 datas = new String[collectList.size()];
                 int index = 0;
-                for (ForecastPowerShortTermStation f : collectList) {
+                for (ForecastPowerShortTermRegulation f : collectList) {
                     datas[index] = String.valueOf(f.getFpValue());
                     index++;
                 }