Kaynağa Gözat

首页修改

wangb 1 yıl önce
ebeveyn
işleme
9be526487c

+ 34 - 27
web/runeconomy-xk/src/main/java/com/gyee/runeconomy/service/monitor/MonitorService.java

@@ -2044,7 +2044,7 @@ public class MonitorService {
                 gf_r_sjdl = gf_r_sjdl + gfrfdlsj;
                 gf_y_sjdl = gf_y_sjdl + gfyfdlsj;
                 gf_n_sjdl = gf_n_sjdl + gfnfdlsj;
-            } else {
+            }
 
                 for (ProBasicPowerstation wp : wplist) {
 
@@ -2063,49 +2063,56 @@ public class MonitorService {
                             nfdljh = valuemap.get("nfdljh");
                         }
                         if (wp.getId().indexOf("FDC_STA") >= 0) {
-                            //日发电量
-                            ProBasicPowerstationPoint rfdlvalue = proBasicPowerstationPointService.getPowerstationPoint(wp.getId(), ContantXk.RFDL);
-                            rfdlsj = edosUtil.getRealData(rfdlvalue).getPointValueInDouble();
-                            //月发电量
-                            ProBasicPowerstationPoint yfdlvalue = proBasicPowerstationPointService.getPowerstationPoint(wp.getId(), ContantXk.YFDL);
-                            yfdlsj = edosUtil.getRealData(yfdlvalue).getPointValueInDouble();
-                            //年发电量
-                            ProBasicPowerstationPoint nfdlvalue = proBasicPowerstationPointService.getPowerstationPoint(wp.getId(), ContantXk.NFDL);
-                            nfdlsj = edosUtil.getRealData(nfdlvalue).getPointValueInDouble();
 
+                            if (wpId.endsWith("STA")) {
+                                //日发电量
+                                ProBasicPowerstationPoint rfdlvalue = proBasicPowerstationPointService.getPowerstationPoint(wp.getId(), ContantXk.RFDL);
+                                rfdlsj = edosUtil.getRealData(rfdlvalue).getPointValueInDouble();
+                                //月发电量
+                                ProBasicPowerstationPoint yfdlvalue = proBasicPowerstationPointService.getPowerstationPoint(wp.getId(), ContantXk.YFDL);
+                                yfdlsj = edosUtil.getRealData(yfdlvalue).getPointValueInDouble();
+                                //年发电量
+                                ProBasicPowerstationPoint nfdlvalue = proBasicPowerstationPointService.getPowerstationPoint(wp.getId(), ContantXk.NFDL);
+                                nfdlsj = edosUtil.getRealData(nfdlvalue).getPointValueInDouble();
+
+                                fd_r_sjdl = fd_r_sjdl + rfdlsj;
+                                fd_y_sjdl = fd_y_sjdl + yfdlsj;
+                                fd_n_sjdl = fd_n_sjdl + nfdlsj;
+                            }
                             fd_r_jhdl = fd_r_jhdl + yfdljh / 30;
                             fd_y_jhdl = fd_y_jhdl + yfdljh;
                             fd_n_jhdl = fd_n_jhdl + nfdljh;
 
-                            fd_r_sjdl = fd_r_sjdl + rfdlsj;
-                            fd_y_sjdl = fd_y_sjdl + yfdlsj;
-                            fd_n_sjdl = fd_n_sjdl + nfdlsj;
-                        } else {
-                            //日发电量
-                            ProBasicPowerstationPoint rfdlvalue = proBasicPowerstationPointService.getPowerstationPoint(wp.getId(), ContantXk.RFDL);
-                            rfdlsj = edosUtil.getRealData(rfdlvalue).getPointValueInDouble();
-                            //月发电量
-                            ProBasicPowerstationPoint yfdlvalue = proBasicPowerstationPointService.getPowerstationPoint(wp.getId(), ContantXk.YFDL);
-                            yfdlsj = edosUtil.getRealData(yfdlvalue).getPointValueInDouble();
 
-                            //年发电量
-                            ProBasicPowerstationPoint nfdlvalue = proBasicPowerstationPointService.getPowerstationPoint(wp.getId(), ContantXk.NFDL);
-                            nfdlsj = edosUtil.getRealData(nfdlvalue).getPointValueInDouble();
+                        } else {
 
+                            if (wpId.endsWith("STA")) {
+                                //日发电量
+                                ProBasicPowerstationPoint rfdlvalue = proBasicPowerstationPointService.getPowerstationPoint(wp.getId(), ContantXk.RFDL);
+                                rfdlsj = edosUtil.getRealData(rfdlvalue).getPointValueInDouble();
+                                //月发电量
+                                ProBasicPowerstationPoint yfdlvalue = proBasicPowerstationPointService.getPowerstationPoint(wp.getId(), ContantXk.YFDL);
+                                yfdlsj = edosUtil.getRealData(yfdlvalue).getPointValueInDouble();
+
+                                //年发电量
+                                ProBasicPowerstationPoint nfdlvalue = proBasicPowerstationPointService.getPowerstationPoint(wp.getId(), ContantXk.NFDL);
+                                nfdlsj = edosUtil.getRealData(nfdlvalue).getPointValueInDouble();
+
+                                gf_r_sjdl = gf_r_sjdl + rfdlsj;
+                                gf_y_sjdl = gf_y_sjdl + yfdlsj;
+                                gf_n_sjdl = gf_n_sjdl + nfdlsj;
+                            }
                             gf_r_jhdl = gf_r_jhdl + yfdljh / 30;
                             gf_y_jhdl = gf_y_jhdl + yfdljh;
                             gf_n_jhdl = gf_n_jhdl + nfdljh;
 
-                            gf_r_sjdl = gf_r_sjdl + rfdlsj;
-                            gf_y_sjdl = gf_y_sjdl + yfdlsj;
-                            gf_n_sjdl = gf_n_sjdl + nfdlsj;
                         }
 
 
                     }
 
                 }
-            }
+
 
             if (wpId.contains("FL")) {
                 gf_r_jhdl = 0;