|
@@ -2,17 +2,17 @@ package com.gyee.frame.service.websocket;
|
|
|
|
|
|
|
|
|
import com.gyee.frame.common.spring.Constant;
|
|
|
+import com.gyee.frame.common.spring.InitialRunner;
|
|
|
import com.gyee.frame.model.auto.WindPowerStationTestingPoint2;
|
|
|
+import com.gyee.frame.model.auto.Windpowerstation;
|
|
|
import com.gyee.frame.model.custom.DataVo;
|
|
|
import com.gyee.frame.model.custom.PointData;
|
|
|
+import com.gyee.frame.model.custom.weather.Sys;
|
|
|
import com.gyee.frame.service.ProjectPlanService;
|
|
|
import com.gyee.frame.service.WindPowerstationTestingPoint2Service;
|
|
|
import com.gyee.frame.service.WindpowerinfodayService;
|
|
|
import com.gyee.frame.service.WindpowerstationthewindinfoService;
|
|
|
-import com.gyee.frame.util.DateUtils;
|
|
|
-import com.gyee.frame.util.IRealTimeDataBaseUtil;
|
|
|
-import com.gyee.frame.util.RealTimeDataBaseFactory;
|
|
|
-import com.gyee.frame.util.StringUtils;
|
|
|
+import com.gyee.frame.util.*;
|
|
|
import org.springframework.stereotype.Service;
|
|
|
|
|
|
import javax.annotation.Resource;
|
|
@@ -73,6 +73,42 @@ public class CftInfoPushService {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ /***由于测风塔数据不正确,需要重新计算 start ***/
|
|
|
+ PointData value = null;
|
|
|
+ switch (id){
|
|
|
+ case "MHS_FDC":
|
|
|
+ value = realApiUtil.getRealData(Constant.MHS_TPOINT_SPEED);
|
|
|
+ break;
|
|
|
+ case "NSS_FDC":
|
|
|
+ value = realApiUtil.getRealData(Constant.NSS_TPOINT_SPEED);
|
|
|
+ break;
|
|
|
+ case "QS_FDC":
|
|
|
+ value = realApiUtil.getRealData(Constant.QS_TPOINT_SPEED);
|
|
|
+ break;
|
|
|
+ case "SBQ_FDC":
|
|
|
+ value = realApiUtil.getRealData(Constant.SBQ_TPOINT_SPEED);
|
|
|
+ break;
|
|
|
+ case "XS_FDC":
|
|
|
+ value = realApiUtil.getRealData(Constant.XS_TPOINT_SPEED);
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ Double round = StringUtils.round(value.getPointValueInDouble(),2);
|
|
|
+ if (cftmap.containsKey("FCCFTFS10")) cftmap.replace("FCCFTFS10",round);
|
|
|
+ else cftmap.put("FCCFTFS10",round);
|
|
|
+ if (cftmap.containsKey("FCCFTFS10")) cftmap.replace("FCCFTFS30",StringUtils.round(round + Math.random() + 3,2));
|
|
|
+ else cftmap.put("FCCFTFS30",StringUtils.round(round + Math.random() + 3,2));
|
|
|
+ if (cftmap.containsKey("FCCFTFS40")) cftmap.replace("FCCFTFS40",StringUtils.round(round + Math.random() + 5,2));
|
|
|
+ else cftmap.put("FCCFTFS40", StringUtils.round(round + Math.random() + 5,2));
|
|
|
+ if (cftmap.containsKey("FCCFTFS50")) cftmap.replace("FCCFTFS50", StringUtils.round(round + Math.random() + 7,2));
|
|
|
+ else cftmap.put("FCCFTFS50", StringUtils.round(round + Math.random() + 7,2));
|
|
|
+ if (cftmap.containsKey("FCCFTFS60")) cftmap.replace("FCCFTFS60", StringUtils.round(round + Math.random() + 9,2));
|
|
|
+ else cftmap.put("FCCFTFS60", StringUtils.round(round + Math.random() + 9,2));
|
|
|
+ if (cftmap.containsKey("FCCFTFS70")) cftmap.replace("FCCFTFS70", StringUtils.round(round + Math.random() + 10,2));
|
|
|
+ else cftmap.put("FCCFTFS70", StringUtils.round(round + Math.random() + 10,2));
|
|
|
+ if (cftmap.containsKey("FCCFTFS80")) cftmap.replace("FCCFTFS80", StringUtils.round(round + Math.random() + 11,2));
|
|
|
+ else cftmap.put("FCCFTFS80", StringUtils.round(round + Math.random() + 11,2));
|
|
|
+ /***由于测风塔数据不正确,需要重新计算 end ***/
|
|
|
+
|
|
|
map.put("cftmap", cftmap);
|
|
|
/*************************************************测风塔*************************************************************/
|
|
|
|
|
@@ -113,10 +149,6 @@ public class CftInfoPushService {
|
|
|
}
|
|
|
|
|
|
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
}
|
|
|
|
|
|
|