zhaomiao 4 anni fa
parent
commit
ba273b658a

+ 6 - 6
src/assets/css/benchmarkingSys/yardBenchmark.scss

@@ -9,12 +9,12 @@
   min-height: 36px;
   margin-top: -15px;
 }
-/deep/::-webkit-scrollbar {
-  z-index: 99999999;
-  width: 6px;
-  height: 13px !important;
-  background-color: #f5f5f5;
-}
+// /deep/::-webkit-scrollbar {
+//   z-index: 99999999;
+//   width: 6px;
+//   height: 13px !important;
+//   background-color: #f5f5f5;
+// }
 .item {
   margin-top: 10px;
   margin-right: 40px;

+ 22 - 24
src/assets/js/benchmarkingSys/yardBenchmark.js

@@ -1,7 +1,4 @@
-
 import * as echarts from "echarts";
-// import formateDate from "@/utils/date";
-// import formateDate1 from "@/utils/date_1";
 export default {
   data() {
     return {
@@ -163,11 +160,12 @@ export default {
       this.selectrowdate = val;
     },
     query_fc() {
-       var newData = new Date();
-       this.beginDate = this.BASE.getBzDate(newData.getTime(), -1);
-       this.endDate = this.BASE.getBzDate(newData.getTime(), 0);
-      this.$http.get("powercompare/windfarmAjax?").then((res) => {
-        this.FClist = res.data.data;
+      let that = this ;
+      var newData = new Date();
+       this.beginDate = this.BASE.getBzDate(newData,-1);
+       this.endDate = this.BASE.getBzDate(newData,0);
+       this.API.get("powercompare/windfarmAjax?").then((res) => {
+        that.FClist = res.data;
       });
     },
     alert_jg() {
@@ -220,27 +218,27 @@ export default {
       page.append("wpId", this.fc);
       page.append("beginDate", this.beginDate);
       page.append("endDate", this.endDate);
-      this.$http.post("/contrast/benchmarkWpList", page).then((res) => {
-        this.tableData = res.data.data;
+      this.API.post("/contrast/benchmarkWpList", page).then((res) => {
+        this.tableData = res.data;
         let len = this.tableData.length;
         for (let i = 0; i < len; i++) {
-          // that.histogram.date[i] = formateDate(
-          //   new Date(res.data.data[i].recordDate) / 1000
-          // );
+          that.histogram.date[i] = this.BASE.getBzDate(
+            new Date(res.data[i].recordDate) / 1000,0
+          );
           
-            that.histogram.xdss[i] = res.data.data[i].xdss;
+            that.histogram.xdss[i] = res.data[i].xdss;
           
 
           
-            that.histogram.gzss[i] = res.data.data[i].gzss;
+            that.histogram.gzss[i] = res.data[i].gzss;
           
 
           
-            that.histogram.jxss[i] = res.data.data[i].whss;
+            that.histogram.jxss[i] = res.data[i].whss;
          
-            that.histogram.xnss[i] = res.data.data[i].qfss;
+            that.histogram.xnss[i] = res.data[i].qfss;
           
-            that.histogram.slss[i] = res.data.data[i].slss;
+            that.histogram.slss[i] = res.data[i].slss;
           
         }
 
@@ -250,7 +248,7 @@ export default {
     filter_date(cellValue) {
       let date = new Date(cellValue.recordDate);
 
-      // return formateDate(date / 1000);
+      return this.BASE.getBzDate(date / 1000,0);
     },
     drawleidatu() {
       var chartDom = document.getElementById("leidatu");
@@ -309,11 +307,11 @@ export default {
             data: [
               {
                 value: this.getChartDataValue,
-                name: formateDate(new Date(this.wp_n_1.recordDate) / 1000),
+                name: this.BASE.getBzDate(new Date(this.wp_n_1.recordDate) / 1000,0),
               },
               {
                 value: this.getChartDataValue2,
-                name: formateDate(new Date(this.wp_n_2.recordDate) / 1000),
+                name: this.BASE.getBzDate(new Date(this.wp_n_2.recordDate) / 1000,0),
               },
             ],
           },
@@ -368,8 +366,8 @@ export default {
           {
             type: "category",
             data: [
-              formateDate(new Date(this.wp_n_1.recordDate) / 1000),
-              formateDate(new Date(this.wp_n_2.recordDate) / 1000),
+              this.BASE.getBzDate(new Date(this.wp_n_1.recordDate) / 1000,0),
+              this.BASE.getBzDate(new Date(this.wp_n_2.recordDate) / 1000,0),
             ],
             axisPointer: {
               type: "shadow",
@@ -497,6 +495,6 @@ export default {
   },
   mounted() {
     this.query_fc();
-    // this.query_benchmarkWpList();
+    this.query_benchmarkWpList();
   },
 };

+ 2 - 2
src/views/benchmarkingSys/yardBenchmark.vue

@@ -1,7 +1,7 @@
 <template>
   <el-container>
     <el-header>
-      <el-card style="margin-top: -10px">
+      <el-card style="margin-top: -10px ; width : 100%">
         <el-row :gutter="1">
           <el-form :inline="true" class="demo-form-inline">
             <el-form-item label="风场">
@@ -341,5 +341,5 @@ export default yardBenchmark;
 </script>
 
 <style lang="scss" scoped>
-// @import "@assets/css/benchmarkingSys/yardBenchmark.scss";
+ @import "@assets/css/benchmarkingSys/yardBenchmark.scss";
 </style>