Browse Source

可靠性能分析

lining 3 years ago
parent
commit
73c363173b

+ 54 - 0
src/api/wisdomOverhaul/reliability/index.js

@@ -0,0 +1,54 @@
+import request from "../../../tools/request";
+
+const analysisDetail = (data) => {
+    return request({
+        baseURL: process.env.VUE_APP_Matrix,
+        url: `/analysis/detail?station=${data.station}&startTs=${data.startTs}&endTs=${data.endTs}&interval=${data.interval}&wtId=${data.wtId}&name=${data.name}`,
+        method: "get",
+    });
+};
+const countQuery = (showLoading,data) => {
+    return request({
+        showLoading,
+        baseURL: process.env.VUE_APP_Matrix,
+        url: `alarm/count/query/new2?stationid=${data.stationid}&startdate=${data.startdate}&enddate=${data.enddate}`,
+        method: "get",
+    });
+};
+const treeType = (data) => {
+    return request({
+        baseURL: process.env.VUE_APP_Matrix,
+        url: `Stoptype/treeType`,
+        method: "get",
+    });
+};
+const shutdownList = (data) => {
+    return request({
+        baseURL: process.env.VUE_APP_Matrix,
+        url: `shutdown/list?stId=${data.stId}&endDate=${data.endDate}&startDate=${data.startDate}`,
+        method: "get",
+    });
+};
+const earlyWarn = (data) => {
+    return request({
+        baseURL: process.env.VUE_APP_Matrix,
+        url: `reliability/earlyWarn?wpid=${data.wpid}&date=${data.date}`,
+        method: "get",
+    });
+};
+const failurestatistics = (data) => {
+    return request({
+        baseURL: process.env.VUE_APP_Matrix,
+        url: `reliability/failurestatistics?wpid=${data.wpid}&date=${data.date}`,
+        method: "get",
+    });
+};
+
+export default {
+    analysisDetail,
+    countQuery,
+    treeType,
+    shutdownList,
+    earlyWarn,
+    failurestatistics,
+}

File diff suppressed because it is too large
+ 711 - 651
src/views/NewPages/alarm-center-1.vue


+ 8 - 18
src/views/NewPages/alarm-center-2.vue

@@ -59,6 +59,8 @@
 import Panel3 from "../../components/coms/panel/panel3.vue";
 import Table2 from "../../components/coms/table/table2.vue";
 import FX from "./alarm-center-gzfx.vue";
+import apis from "@api/wisdomOverhaul/health/index.js";
+import api from "@api/wisdomOverhaul/reliability/index.js";
 export default {
   components: { Panel3, Table2,FX },
   data () {
@@ -138,7 +140,7 @@ export default {
         ],
         data: [
           {
-            name: "MG01_01",
+            name: "",
             v1: {
               count: 12,
               time: 0,
@@ -159,20 +161,13 @@ export default {
   methods: {
     tabSelect (tab) { },
     async search () {
-      const { data } = await this.API.requestData({
-        subUrl: "powercompare/windfarmAjax",
-      });
+      const { data } = await apis.powercompareWindfarmAjax();
       this.wpoptions = data.data;
       this.wpvalue = data.data[0].id;
       this.searchData();
     },
     async searchTree () {
-      const { data } = await this.API.requestData({
-        baseURL: "http://192.168.1.18:8075/",
-        subUrl: "Stoptype/treeType",
-      });
-
-      
+      const { data } = await api.treeType()
       this.cascaderOptions = data.data;
       let arr = [];
       let columnObj = [
@@ -196,16 +191,11 @@ export default {
     },
     async searchData () {
 		let enddate = new Date(Date.parse(new Date(this.enddate)) + (24*3600*1000)).formatDate("yyyy-MM-dd");
-      const { data } = await this.API.requestData({
-		  showLoading:true,
-        baseURL: "http://192.168.1.18:8075/",
-        subUrl: "shutdown/list",
-        data: {
-          stId: this.wpvalue,
+      const { data } = await api.shutdownList({
+        stId: this.wpvalue,
           endDate: new Date(this.startdate).formatDate("yyyy-MM-dd"),
           startDate: enddate,
-        },
-      });
+      })
       ////////
       const resData = data.data;
       // const resData =this.resdata;

+ 17 - 25
src/views/malfunctionStatistics/index.vue

@@ -106,6 +106,8 @@
 </template>
 
 <script>
+import apis from "@api/wisdomOverhaul/health/index.js";
+import api from "@api/wisdomOverhaul/reliability/index.js";
 export default {
   // 名称
   name: "cutAnalyse",
@@ -138,40 +140,30 @@ export default {
   methods: {
     // 请求服务
     requestData () {
-      let that = this;
-      that.API.requestData({
-        method: "GET",
-        subUrl: "powercompare/windfarmAjax",
-        success (res) {
-          that.wpArray = res.data;
-          that.wpId = res.data[0].id;
-          that.getTableData();
-        }
+      apis.powercompareWindfarmAjax().then((res) => {
+        this.wpArray = res.data;
+        this.wpId = res.data[0].id;
+        this.getTableData();
       });
     },
 
     getTableData () {
-      let that = this;
-      if (!that.wpId || !that.recorddate) {
-        that.BASE.showMsg({
+      if (!this.wpId || !this.recorddate) {
+        this.BASE.showMsg({
           msg: "场站与日期不可为空"
         });
       } else {
-        that.API.requestData({
-          method: "GET",
-          baseURL: "http://10.155.32.4:8034/",
-          subUrl: "reliability/failurestatistics",
-          data: {
-            wpid: that.wpId,
-            date: that.recorddate
-          },
-          success (res) {
+        api
+          .failurestatistics({
+            wpid: this.wpId,
+            date: this.recorddate,
+          })
+          .then((res) => {
             if (res.data.length) {
-              that.tableTitle = res.data[0].wpname + "故障统计";
-              that.tableData.data = res.data;
+              this.tableTitle = res.data[0].wpname + "故障统计";
+              this.tableData.data = res.data;
             }
-          }
-        });
+          });
       }
     },
 

+ 43 - 51
src/views/sampleDatabase/warning/index.vue

@@ -61,7 +61,7 @@
         <div class="query-actions">
           <button class="btn" @click="query">查询</button>
           <!-- <button class="btn" @click="">导入</button> -->
-          <button class="btn" @click="export">导出</button>
+          <button class="btn" @click="exports">导出</button>
         </div>
       </div>
     </div>
@@ -124,6 +124,7 @@
 import ComTable from "@com/coms/table/table.vue";
 import MultipleYLineChartNormal from "../../NewPages/multiple-y-line-chart-normal.vue";
 import BASE from "@tools/basicTool.js";
+import api from "@api/wisdomOverhaul/reliability/index.js";
 export default {
   components: {
     ComTable,
@@ -249,7 +250,7 @@ export default {
             is_light: false,
             width: "200px",
             template: function () {
-              return ("<el-button type='text' style='cursor: pointer;' value='config'>原始数据</el-button>&nbsp");
+              return "<el-button type='text' style='cursor: pointer;' value='config'>原始数据</el-button>&nbsp";
             },
             click: function (event, data) {
               that.yssjTitle = data.yjms;
@@ -273,28 +274,27 @@ export default {
   },
   methods: {
     requestDetailData(wpId, fjbh, yjms, time) {
-      let that = this;
-      that.yssjData = {
+      this.yssjData = {
         wpId: wpId,
         fjbh: fjbh,
         yjms: yjms,
         time: time,
       };
       BASE.showLoading();
-      that.API.requestData({
-        method: "GET",
-        subUrl: "/analysis/detail",
-        data: {
+      api
+        .analysisDetail({
           station: wpId,
-          startTs: new Date(new Date(time[0]).formatDate("yyyy/MM/dd")).getTime(),
+          startTs: new Date(
+            new Date(time[0]).formatDate("yyyy/MM/dd")
+          ).getTime(),
           endTs: new Date(new Date(time[1]).formatDate("yyyy/MM/dd")).getTime(),
-          interval: that.selectValue,
+          interval: this.selectValue,
           wtId: fjbh,
           name: yjms,
-        },
-        success(res) {
+        })
+        .then((res) => {
           if (res.data.length == 1) {
-            that.yssjDialog = true;
+            this.yssjDialog = true;
             BASE.closeLoading();
             let yaxises = [
               {
@@ -307,7 +307,7 @@ export default {
             ];
             // yaxises.name = res.data[0].name;
             yaxises.unit = res.data[0].unit;
-            that.AnalysisYAxises = yaxises;
+            this.AnalysisYAxises = yaxises;
             let aKey1 = ["doubleValue"];
             let aList1 = [
               {
@@ -326,9 +326,9 @@ export default {
                 });
               });
             });
-            that.Analysis = aList1;
+            this.Analysis = aList1;
           } else if (res.data.length == 2) {
-            that.yssjDialog = true;
+            this.yssjDialog = true;
             BASE.closeLoading();
             let aKey2 = ["doubleValue", "doubleValue"];
             let aList2 = [
@@ -367,7 +367,7 @@ export default {
                 aEle.unit = rEle.unit;
               });
             });
-            that.AnalysisYAxises = yaxises1;
+            this.AnalysisYAxises = yaxises1;
             aKey2.forEach((keyEle, keyIndex) => {
               aList2[keyIndex].title = res.data[keyIndex].name;
               res.data[keyIndex].data.forEach((rEle) => {
@@ -377,9 +377,9 @@ export default {
                 });
               });
             });
-            that.Analysis = aList2;
+            this.Analysis = aList2;
           } else if (res.data.length == 4) {
-            that.yssjDialog = true;
+            this.yssjDialog = true;
             BASE.closeLoading();
             let aKey4 = [
               "doubleValue",
@@ -435,7 +435,7 @@ export default {
                 aEle.unit = rEle.unit;
               });
             });
-            that.AnalysisYAxises = yaxises2;
+            this.AnalysisYAxises = yaxises2;
             aKey4.forEach((keyEle, keyIndex) => {
               aList4[keyIndex].title = res.data[keyIndex].name;
               res.data[keyIndex].data.forEach((rEle) => {
@@ -445,22 +445,21 @@ export default {
                 });
               });
             });
-            that.Analysis = aList4;
+            this.Analysis = aList4;
           } else if (res.data.length == 0) {
-            that.yssjDialog = false;
+            this.yssjDialog = false;
             BASE.closeLoading();
-            that.BASE.showMsg({
+            this.BASE.showMsg({
               type: "warning",
               msg: "暂无数据",
             });
           } else {
             BASE.closeLoading();
-            that.BASE.showMsg({
+            this.BASE.showMsg({
               msg: "暂无数据",
             });
           }
-        },
-      });
+        });
     },
     queryYssj() {
       let data = this.yssjData;
@@ -499,30 +498,24 @@ export default {
     },
     // 获取停机事件
     requestSafeList() {
-      let that = this;
       // if (wtIdData) {
-      // 	that.tableData.data = wtIdData;
-      // 	that.wtIdData = [];
+      // 	this.tableData.data = wtIdData;
+      // 	this.wtIdData = [];
       // 	return;
       // }
       // if (wpId) {
-      // 	that.wpId = wpId;
+      // 	this.wpId = wpId;
       // }
-      that.month[0] = that.formatDate(that.month[0].valueOf());
-      that.month[1] = that.formatDate(that.month[1].valueOf());
+      this.month[0] = this.formatDate(this.month[0].valueOf());
+      this.month[1] = this.formatDate(this.month[1].valueOf());
       let data = {
-        stationid: that.wpId,
-        startdate: that.month[0].valueOf(),
-        enddate: that.month[1].valueOf(),
+        stationid: this.wpId,
+        startdate: this.month[0].valueOf(),
+        enddate: this.month[1].valueOf(),
       };
-      that.API.requestData({
-        showLoading: true,
-        baseURL: "http://192.168.1.18:8075/",
-        subUrl: "alarm/count/query/new2",
-        data,
-        success(res) {
-          if (res.code == 200) {
-            that.tableData.data = [];
+      api.countQuery(data).then(res =>{
+        if (res.code == 200) {
+            this.tableData.data = [];
             if (res.data.length) {
               let data = res.data;
               let tabData = [];
@@ -551,17 +544,16 @@ export default {
                   }
                 });
               });
-              that.wtIdArr = wtIdArr;
-              that.wtId = wtIdArr;
-              that.tableData.data = tabData;
-              that.tableDataArr = {
-                column: that.tableData.column,
+              this.wtIdArr = wtIdArr;
+              this.wtId = wtIdArr;
+              this.tableData.data = tabData;
+              this.tableDataArr = {
+                column: this.tableData.column,
                 data: tabData,
               };
             }
           }
-        },
-      });
+      })
     },
     query() {
       this.requestSafeList();
@@ -579,7 +571,7 @@ export default {
     formatJson(filterVal, jsonData) {
       return jsonData.map((v) => filterVal.map((j) => v[j]));
     },
-    export() {
+    exports() {
       let that = this;
       const { export_json_to_excel } = require("@tools/excel/Export2Excel.js"); // 注意这个Export2Excel路径
       let tHeader = []; // 上面设置Excel的表格第一行的标题

+ 266 - 75
src/views/warnStatistics/index.vue

@@ -5,15 +5,31 @@
         <div class="query-item">
           <div class="lable">场站:</div>
           <div class="search-input">
-            <el-select v-model="wpId" clearable placeholder="请选择" popper-class="select">
-              <el-option v-for="item in wpArray" :key="item.id" :value="item.id" :label="item.name" />
+            <el-select
+              v-model="wpId"
+              clearable
+              placeholder="请选择"
+              popper-class="select"
+            >
+              <el-option
+                v-for="item in wpArray"
+                :key="item.id"
+                :value="item.id"
+                :label="item.name"
+              />
             </el-select>
           </div>
         </div>
         <div class="query-item">
           <div class="lable">日期:</div>
           <div class="search-input">
-            <el-date-picker v-model="recorddate" type="date" value-format="YYYY-MM-DD" placeholder="选择日期" popper-class="date-select">
+            <el-date-picker
+              v-model="recorddate"
+              type="date"
+              value-format="YYYY-MM-DD"
+              placeholder="选择日期"
+              popper-class="date-select"
+            >
             </el-date-picker>
           </div>
         </div>
@@ -23,101 +39,286 @@
       </div>
     </div>
     <div class="df-table curTable">
-      <el-table class="custom-table" :data="tableData.data" height="88vh" max-height="88vh" stripe style="width: 100%" :border="true">
-        <el-table-column :show-overflow-tooltip="true" prop="wtname" label="风机" width="150px"></el-table-column>
+      <el-table
+        class="custom-table"
+        :data="tableData.data"
+        height="88vh"
+        max-height="88vh"
+        stripe
+        style="width: 100%"
+        :border="true"
+      >
+        <el-table-column
+          :show-overflow-tooltip="true"
+          prop="wtname"
+          label="风机"
+          width="150px"
+        ></el-table-column>
         <el-table-column :show-overflow-tooltip="true" :label="tableTitle">
           <el-table-column :show-overflow-tooltip="true" label="近一天">
             <el-table-column :show-overflow-tooltip="true" label="1">
-              <el-table-column :show-overflow-tooltip="true" prop="day1top1name" label="故障" width="200px"></el-table-column>
-              <el-table-column :show-overflow-tooltip="true" prop="day1top1" label="频次" :sortable="true" width="150px"></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day1top1name"
+                label="故障"
+                width="200px"
+              ></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day1top1"
+                label="频次"
+                :sortable="true"
+                width="150px"
+              ></el-table-column>
             </el-table-column>
             <el-table-column :show-overflow-tooltip="true" label="2">
-              <el-table-column :show-overflow-tooltip="true" prop="day1top2name" label="故障" width="200px"></el-table-column>
-              <el-table-column :show-overflow-tooltip="true" prop="day1top2" label="频次" :sortable="true"></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day1top2name"
+                label="故障"
+                width="200px"
+              ></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day1top2"
+                label="频次"
+                :sortable="true"
+              ></el-table-column>
             </el-table-column>
             <el-table-column :show-overflow-tooltip="true" label="3">
-              <el-table-column :show-overflow-tooltip="true" prop="day1top3name" label="故障"></el-table-column>
-              <el-table-column :show-overflow-tooltip="true" prop="day1top3" label="频次" :sortable="true" width="150px"></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day1top3name"
+                label="故障"
+              ></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day1top3"
+                label="频次"
+                :sortable="true"
+                width="150px"
+              ></el-table-column>
             </el-table-column>
           </el-table-column>
           <el-table-column :show-overflow-tooltip="true" label="近三天">
             <el-table-column :show-overflow-tooltip="true" label="1">
-              <el-table-column :show-overflow-tooltip="true" prop="day3top1name" label="故障"></el-table-column>
-              <el-table-column :show-overflow-tooltip="true" prop="day3top1" label="频次" :sortable="true"></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day3top1name"
+                label="故障"
+              ></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day3top1"
+                label="频次"
+                :sortable="true"
+              ></el-table-column>
             </el-table-column>
             <el-table-column :show-overflow-tooltip="true" label="2">
-              <el-table-column :show-overflow-tooltip="true" prop="day3top2name" label="故障" width="200px"></el-table-column>
-              <el-table-column :show-overflow-tooltip="true" prop="day3top2" label="频次" :sortable="true" width="150px"></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day3top2name"
+                label="故障"
+                width="200px"
+              ></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day3top2"
+                label="频次"
+                :sortable="true"
+                width="150px"
+              ></el-table-column>
             </el-table-column>
             <el-table-column :show-overflow-tooltip="true" label="3">
-              <el-table-column :show-overflow-tooltip="true" prop="day3top3name" label="故障" width="200px"></el-table-column>
-              <el-table-column :show-overflow-tooltip="true" prop="day3top3" label="频次" :sortable="true" width="150px"></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day3top3name"
+                label="故障"
+                width="200px"
+              ></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day3top3"
+                label="频次"
+                :sortable="true"
+                width="150px"
+              ></el-table-column>
             </el-table-column>
           </el-table-column>
           <el-table-column :show-overflow-tooltip="true" label="近七天">
             <el-table-column :show-overflow-tooltip="true" label="1">
-              <el-table-column :show-overflow-tooltip="true" prop="day7top1name" label="故障" width="200px"></el-table-column>
-              <el-table-column :show-overflow-tooltip="true" prop="day7top1" label="频次" :sortable="true" width="150px"></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day7top1name"
+                label="故障"
+                width="200px"
+              ></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day7top1"
+                label="频次"
+                :sortable="true"
+                width="150px"
+              ></el-table-column>
             </el-table-column>
             <el-table-column :show-overflow-tooltip="true" label="2">
-              <el-table-column :show-overflow-tooltip="true" prop="day7top2name" label="故障" width="200px"></el-table-column>
-              <el-table-column :show-overflow-tooltip="true" prop="day7top2" label="频次" :sortable="true" width="150px"></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day7top2name"
+                label="故障"
+                width="200px"
+              ></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day7top2"
+                label="频次"
+                :sortable="true"
+                width="150px"
+              ></el-table-column>
             </el-table-column>
             <el-table-column :show-overflow-tooltip="true" label="3">
-              <el-table-column :show-overflow-tooltip="true" prop="day7top3name" label="故障" width="200px"></el-table-column>
-              <el-table-column :show-overflow-tooltip="true" prop="day7top3" label="频次" :sortable="true" width="150px"></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day7top3name"
+                label="故障"
+                width="200px"
+              ></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day7top3"
+                label="频次"
+                :sortable="true"
+                width="150px"
+              ></el-table-column>
             </el-table-column>
           </el-table-column>
           <el-table-column :show-overflow-tooltip="true" label="近十五天">
             <el-table-column :show-overflow-tooltip="true" label="1">
-              <el-table-column :show-overflow-tooltip="true" prop="day15top1name" label="故障" width="200px"></el-table-column>
-              <el-table-column :show-overflow-tooltip="true" prop="day15top1" label="频次" :sortable="true" width="150px"></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day15top1name"
+                label="故障"
+                width="200px"
+              ></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day15top1"
+                label="频次"
+                :sortable="true"
+                width="150px"
+              ></el-table-column>
             </el-table-column>
             <el-table-column :show-overflow-tooltip="true" label="2">
-              <el-table-column :show-overflow-tooltip="true" prop="day15top2name" label="故障" width="200px"></el-table-column>
-              <el-table-column :show-overflow-tooltip="true" prop="day15top2" label="频次" :sortable="true" width="150px"></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day15top2name"
+                label="故障"
+                width="200px"
+              ></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day15top2"
+                label="频次"
+                :sortable="true"
+                width="150px"
+              ></el-table-column>
             </el-table-column>
             <el-table-column :show-overflow-tooltip="true" label="3">
-              <el-table-column :show-overflow-tooltip="true" prop="day15top3name" label="故障" width="200px"></el-table-column>
-              <el-table-column :show-overflow-tooltip="true" prop="day15top3" label="频次" :sortable="true" width="150px"></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day15top3name"
+                label="故障"
+                width="200px"
+              ></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="day15top3"
+                label="频次"
+                :sortable="true"
+                width="150px"
+              ></el-table-column>
             </el-table-column>
           </el-table-column>
           <el-table-column :show-overflow-tooltip="true" label="近一个月">
             <el-table-column :show-overflow-tooltip="true" label="1">
-              <el-table-column :show-overflow-tooltip="true" prop="month1top1name" label="故障" width="200px"></el-table-column>
-              <el-table-column :show-overflow-tooltip="true" prop="month1top1" label="频次" :sortable="true" width="150px"></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="month1top1name"
+                label="故障"
+                width="200px"
+              ></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="month1top1"
+                label="频次"
+                :sortable="true"
+                width="150px"
+              ></el-table-column>
             </el-table-column>
             <el-table-column :show-overflow-tooltip="true" label="2">
-              <el-table-column :show-overflow-tooltip="true" prop="month1top2name" label="故障" width="200px"></el-table-column>
-              <el-table-column :show-overflow-tooltip="true" prop="month1top2" label="频次" :sortable="true" width="150px"></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="month1top2name"
+                label="故障"
+                width="200px"
+              ></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="month1top2"
+                label="频次"
+                :sortable="true"
+                width="150px"
+              ></el-table-column>
             </el-table-column>
             <el-table-column :show-overflow-tooltip="true" label="3">
-              <el-table-column :show-overflow-tooltip="true" prop="month1top3name" label="故障" width="200px"></el-table-column>
-              <el-table-column :show-overflow-tooltip="true" prop="month1top3" label="频次" :sortable="true" width="150px"></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="month1top3name"
+                label="故障"
+                width="200px"
+              ></el-table-column>
+              <el-table-column
+                :show-overflow-tooltip="true"
+                prop="month1top3"
+                label="频次"
+                :sortable="true"
+                width="150px"
+              ></el-table-column>
             </el-table-column>
           </el-table-column>
         </el-table-column>
       </el-table>
     </div>
-    <el-dialog title="切入切出风速整合历史" v-model="dialogShow" width="85%" top="10vh" custom-class="modal"
-      :close-on-click-modal="true" @closed="dialogType = ''">
+    <el-dialog
+      title="切入切出风速整合历史"
+      v-model="dialogShow"
+      width="85%"
+      top="10vh"
+      custom-class="modal"
+      :close-on-click-modal="true"
+      @closed="dialogType = ''"
+    >
     </el-dialog>
   </div>
 </template>
 
 <script>
+import apis from "@api/wisdomOverhaul/health/index.js";
+import api from "@api/wisdomOverhaul/reliability/index.js";
 export default {
   // 名称
   name: "cutAnalyse",
 
   // 数据
-  data () {
+  data() {
     const that = this;
     return {
       isAsc: "asc",
       wpArray: [],
       wpId: "",
-      recorddate: new Date((new Date().getTime() - 3600 * 1000 * 24)).formatDate("yyyy-MM-dd"),
+      recorddate: new Date(new Date().getTime() - 3600 * 1000 * 24).formatDate(
+        "yyyy-MM-dd"
+      ),
       tableTitle: "",
       tableData: {
         column: [
@@ -126,8 +327,8 @@ export default {
             field: "windturbineid",
             is_num: false,
             is_light: false,
-            sortable: true
-          }
+            sortable: true,
+          },
         ],
         data: [],
       },
@@ -137,56 +338,46 @@ export default {
   // 函数
   methods: {
     // 请求服务
-    requestData () {
-      let that = this;
-      that.API.requestData({
-        method: "GET",
-        subUrl: "powercompare/windfarmAjax",
-        success (res) {
-          that.wpArray = res.data;
-          that.wpId = res.data[0].id;
-          that.getTableData();
-        }
+    requestData() {
+      apis.powercompareWindfarmAjax().then((res) => {
+        this.wpArray = res.data;
+        this.wpId = res.data[0].id;
+        this.getTableData();
       });
     },
 
-    getTableData () {
-      let that = this;
-      if (!that.wpId || !that.recorddate) {
-        that.BASE.showMsg({
-          msg: "场站与日期不可为空"
+    getTableData() {
+      if (!this.wpId || !this.recorddate) {
+        this.BASE.showMsg({
+          msg: "场站与日期不可为空",
         });
       } else {
-        that.API.requestData({
-          method: "GET",
-          baseURL: "http://10.155.32.4:8034/",
-          subUrl: "reliability/earlyWarn",
-          data: {
-            wpid: that.wpId,
-            date: that.recorddate
-          },
-          success (res) {
+        api
+          .earlyWarn({
+            wpid: this.wpId,
+            date: this.recorddate,
+          })
+          .then((res) => {
             if (res.data.length) {
-              that.tableTitle = res.data[0].wpname + "预警统计";
-              that.tableData.data = res.data;
+              this.tableTitle = res.data[0].wpname + "预警统计";
+              this.tableData.data = res.data;
             }
-          }
-        });
+          });
       }
     },
 
-    search () {
+    search() {
       this.getTableData();
-    }
+    },
   },
 
-  created () {
+  created() {
     this.requestData();
   },
 
-  mounted () { },
+  mounted() {},
 
-  unmounted () { },
+  unmounted() {},
 };
 </script>
 
@@ -214,7 +405,7 @@ export default {
     margin-top: 1.481vh;
 
     &:before {
-      content: '';
+      content: "";
       width: 0.37vh;
       height: 0.37vh;
       background: @write;