Browse Source

对风偏差调度

xieshengjie 2 years ago
parent
commit
413c7e0053

+ 22 - 0
realtime/generationXK-service/src/main/java/com/gyee/generation/task/SaticSchedulePgTask.java

@@ -1,6 +1,7 @@
 package com.gyee.generation.task;
 
 
+import com.gyee.common.util.DateUtils;
 import com.gyee.generation.service.*;
 import com.xxl.job.core.context.XxlJobHelper;
 import com.xxl.job.core.handler.annotation.XxlJob;
@@ -76,6 +77,8 @@ public class SaticSchedulePgTask {
 
     @Resource
     private TimelinessRateService timelinessRateService;
+    @Resource
+    private WindDeviationService windDeviationService;
 
 
     /**
@@ -470,4 +473,23 @@ public class SaticSchedulePgTask {
         }
         XxlJobHelper.log("设备数据统计调度任务处理完成!........");
     }
+
+    /**
+     * 对风偏差率
+     * 每日0点15执行
+     */
+
+    @XxlJob("calWindDeviation_PG")
+    public void calWindDeviation_PG()  {
+
+
+        XxlJobHelper.log("对风偏差率调度程序执行开始!........");
+        String yesterdayStr = DateUtils.getYesterdayStr("yyyy-MM-dd");
+        try {
+            windDeviationService.save(yesterdayStr,yesterdayStr);
+        } catch (Exception e) {
+            e.printStackTrace();
+        }
+        XxlJobHelper.log("对风偏差率调度任务处理完成!........");
+    }
 }