lining 3 years ago
parent
commit
16fe3cdd55

+ 21 - 13
src/api/economic/index.js

@@ -176,24 +176,18 @@ const threerateXqjsl = (data) => {
 };
 
 // 发电效率排行
-const powercompareWindfarmAllAjax = (data) => {
-    return request({
-        url: `/consumer/powercompare/windfarmAllAjax?type=${data.type}`,
-        method: "get",
-    });
-};
 
 const leaderboardLoadfactortoplist = (data) => {
     return request({
-        url: `/consumer/leaderboard/loadfactortoplist`,
-        method: "post",
-        data: data
+        url: `/consumer/ranking/efficiencyRanking?beginDate=${data.beginDate}&endDate=${data.endDate}&wpid=${data.wpId}&orderby=${data.orderby}&isAsc=${data.isAsc}`,
+        method: "get",
+
     });
 };
 // 总发电效率排行
 const leaderboardTotalPowerCapacityTopList = (data) => {
     return request({
-        url: `/consumer/leaderboard/totalPowerCapacityTopList?wpIps=${data.wpIps}&isAsc=${data.isAsc}&beginDate=${data.beginDate}&endDate=${data.endDate}&orderByColumn=${data.orderByColumn}`,
+        url: `/consumer/ranking/electricRanking?beginDate=${data.beginDate}&endDate=${data.endDate}&wpid=${data.wpid}&orderby=${data.orderby}&isAsc=${data.isAsc}`,
         method: "get",
     });
 };
@@ -583,7 +577,20 @@ const paramComparisonGeneratingCurve = (data) => {
 
 };
 
-
+//等级评估--获取表格数据
+const levelAssessmentList = (data) => {
+    return request({
+        url: `/consumer/levelAssessment/list?recorddate=${data.recorddate}&type=${data.type}&wpid=${data.wpId}&orderby=${data.orderby}&isAsc=${data.isAsc}`,
+        method: "get",
+    });
+};
+//等级评估--对比
+const levelAssessmentComparison = (data) => {
+    return request({
+        url: `/consumer/levelAssessment/comparison?id1=${data.gaid1}&id2=${data.gaid2}`,
+        method: "get",
+    });
+};
 
 
 export default {
@@ -611,7 +618,6 @@ export default {
     threerateFwjsl,
     threerateZtzhl,
     threerateXqjsl,
-    powercompareWindfarmAllAjax,
     leaderboardLoadfactortoplist,
     leaderboardTotalPowerCapacityTopList,
     leaderboardQuerywarningStatistical,
@@ -665,5 +671,7 @@ export default {
     datacenterRealtimeExport,
     paramComparisonEquipmentStructure,
     paramComparisonEquipmentParams,
-    paramComparisonGeneratingCurve
+    paramComparisonGeneratingCurve,
+    levelAssessmentList,
+    levelAssessmentComparison
 }

+ 2 - 1
src/components/coms/table/table-unpage.vue

@@ -154,6 +154,7 @@ export default {
       if (col.click) col.click(event, data);
     },
     onSort(col) {
+      // console.log(222222222);
       if (col.sortable == true) {
         this.sortCol = col.field;
         switch (this.sortType) {
@@ -164,7 +165,7 @@ export default {
             this.sortType = "ASC";
             break;
           case "ASC":
-            this.sortType = "";
+            this.sortType = "DESC";
             break;
         }
       }

+ 1 - 1
src/components/coms/table/table.vue

@@ -203,7 +203,7 @@ export default {
             this.sortType = "ASC";
             break;
           case "ASC":
-            this.sortType = "";
+            this.sortType = "DESC";
             break;
         }
       }

+ 0 - 2
src/tools/request.js

@@ -34,10 +34,8 @@ service.interceptors.response.use(
 		if (
 			status === 200
 		) {
-
 			return response.data;
 		} else {
-
 			return false;
 		}
 	},

+ 127 - 147
src/views/HealthControl/assess/assessindex.vue

@@ -112,7 +112,8 @@
 import ComTable from "@/components/coms/table/table-unpage.vue";
 import Dayinfo from "../dayinfo.vue";
 import GradeHistory from "../gradeHistory.vue";
-
+import api from "@api/economic/index.js";
+import { registerLoading } from "echarts";
 export default {
   name: "gradeassessment",
   components: { ComTable, Dayinfo, GradeHistory },
@@ -130,7 +131,7 @@ export default {
       hisDialogVisible: false,
       hisDialogTitle: "",
       ChangZhan: [],
-      value1: "MHS_FDC",
+      value1: "CL_FDC",
       date: "",
       shows: "d",
       showTitle: "风机日信息量化评级管理",
@@ -316,64 +317,64 @@ export default {
             sortable: true,
             id: "id",
           },
-          {
-            name: "操作",
-            field: "sjbz",
-            is_num: false,
-            is_light: false,
-            sortable: true,
-            id: "id",
-            template: () => {
-              return "<el-button type='text' style='cursor: pointer;' value='xq'>详情</el-button>&nbsp;<el-button type='text' style='cursor: pointer;' value='ls'>历史</el-button>";
-            },
-            click: function (event, data) {
-              if ("xq" == event.target.getAttribute("value")) {
-                that.dialogVisible = true;
-                that.dialogData1 = [data];
-                const service1 = {
-                  name: data.windturbineid,
-                  value: [
-                    data["yearxfqr"],
-                    data["yearxnssdl"],
-                    data["yearnhyd"],
-                    data["yearglyzxxs"],
-                    data["yearlyxs"],
-                    data["yearsbklyl"],
-                    data["yeardxkyxs"],
-                    data["yearyxfss"],
-                    data["yearfs"],
-                    data["yearjfpl"],
-                  ],
-                };
-                const chartData = [
-                  {
-                    indicator: [
-                      "平均切入风速",
-                      "性能损失电量",
-                      "拟合优度",
-                      "功率一致性系数",
-                      "利用小时",
-                      "设备可利用率",
-                      "等效可利用系数",
-                      "有效风时数",
-                      "平均风速",
-                      "静风频率",
-                    ],
-                    data: [service1],
-                  },
-                ];
-                that.dialogData2 = chartData;
-              }
-              if ("ls" == event.target.getAttribute("value")) {
-                that.hisOption["shows"] = that.shows;
-                that.hisOption["date"] = that.date;
-                that.hisOption["windturbineid"] = data.windturbineid;
-                that.hisDialogTitle = data.windturbineid;
-                that.hisDialogVisible = true;
-                that.$refs.gradeHistory.getTable();
-              }
-            },
-          },
+          // {
+          //   name: "操作",
+          //   field: "sjbz",
+          //   is_num: false,
+          //   is_light: false,
+          //   sortable: true,
+          //   id: "id",
+          //   template: () => {
+          //     return "<el-button type='text' style='cursor: pointer;' value='xq'>详情</el-button>&nbsp;<el-button type='text' style='cursor: pointer;' value='ls'>历史</el-button>";
+          //   },
+          //   click: function (event, data) {
+          //     if ("xq" == event.target.getAttribute("value")) {
+          //       that.dialogVisible = true;
+          //       that.dialogData1 = [data];
+          //       const service1 = {
+          //         name: data.windturbineid,
+          //         value: [
+          //           data["yearxfqr"],
+          //           data["yearxnssdl"],
+          //           data["yearnhyd"],
+          //           data["yearglyzxxs"],
+          //           data["yearlyxs"],
+          //           data["yearsbklyl"],
+          //           data["yeardxkyxs"],
+          //           data["yearyxfss"],
+          //           data["yearfs"],
+          //           data["yearjfpl"],
+          //         ],
+          //       };
+          //       const chartData = [
+          //         {
+          //           indicator: [
+          //             "平均切入风速",
+          //             "性能损失电量",
+          //             "拟合优度",
+          //             "功率一致性系数",
+          //             "利用小时",
+          //             "设备可利用率",
+          //             "等效可利用系数",
+          //             "有效风时数",
+          //             "平均风速",
+          //             "静风频率",
+          //           ],
+          //           data: [service1],
+          //         },
+          //       ];
+          //       that.dialogData2 = chartData;
+          //     }
+          //     if ("ls" == event.target.getAttribute("value")) {
+          //       that.hisOption["shows"] = that.shows;
+          //       that.hisOption["date"] = that.date;
+          //       that.hisOption["windturbineid"] = data.windturbineid;
+          //       that.hisDialogTitle = data.windturbineid;
+          //       that.hisDialogVisible = true;
+          //       that.$refs.gradeHistory.getTable();
+          //     }
+          //   },
+          // },
         ],
         data: [],
       },
@@ -392,49 +393,33 @@ export default {
     },
     // 获取表格数据
     getTable(date) {
-      let that = this;
+      // let that = this;
       let subUrl = "";
       const data = {
-        isAsc: "asc",
+        isAsc: "",
         wpId: this.value1,
+        orderby: "",
       };
       if ("d" == this.shows) {
-        subUrl = "/benchmarking/gadaylistByPage";
         data["recorddate"] = date;
+        data["type"] = 1;
       }
       if ("m" == this.shows) {
-        subUrl = "/benchmarking/gamonthlistByPage";
-        const dateStr = date.split("-");
-        if (dateStr.length > 1) {
-          data["year"] = dateStr[0];
-          data["month"] = dateStr[1];
-        }
+        data["recorddate"] = date;
+        data["type"] = 2;
       }
       if ("y" == this.shows) {
-        subUrl = "/benchmarking/gayearlistByPage";
-        data["year"] = date;
+        data["recorddate"] = date;
+        data["type"] = 3;
       }
-      that.tableLoading = true;
-      
-      that.API.requestData({
-        timeout: 60000,
-        method: "POST",
-        subUrl: subUrl,
-        data: data,
-        success(res) {
-          that.tableLoading = false;
-          if (res.code === 200) {
-            var data = [];
-            res.data.list.forEach((item, index) => {
-              item["index"] = index;
-              data[index] = item;
-            });
-            that.tableData.data = data;
-          }
-        },
-        Error(res) {
-          console.log("tag", res);
-        },
+      this.tableLoading = true;
+
+      api.levelAssessmentList(data).then((res) => {
+        this.tableLoading = false;
+        if (res.code === 200) {
+          var data = [];
+          this.tableData.data = res.data;
+        }
       });
     },
     //   tab
@@ -462,15 +447,9 @@ export default {
     },
     // 场站
     ChangZhanVal() {
-      var that = this;
-      that.API.requestData({
-        method: "GET",
-        baseURL: "http://10.83.66.220:8020/",
-        subUrl: "benchmarking/wplist",
-        success(res) {
-          that.ChangZhan = res.data;
-          that.value1 = res.data[0].id;
-        },
+      api.benchmarkingWplist({}).then((res) => {
+        this.ChangZhan = res.data;
+        this.value1 = res.data[0].id;
       });
     },
     // 查询
@@ -480,66 +459,67 @@ export default {
     },
     // 日信息对比
     contrast() {
-      var that = this;
-      if (that.dataIds.size == 2) {
-        that.dialogVisible = true;
-        const tmpArr = Array.from(that.dataIds);
+      if (this.dataIds.size == 2) {
+        this.dialogVisible = true;
+        const tmpArr = Array.from(this.dataIds);
         const data = {
           gaid1: tmpArr[0],
           gaid2: tmpArr[1],
         };
 
-        that.API.requestData({
-          method: "GET",
-          subUrl: "/benchmarking/wtinfo",
-          data: data,
-          success(res) {
-            that.dialogData1 = [res.data.gaid1, res.data.gaid2];
-          },
-        });
-        that.API.requestData({
-          method: "GET",
-          subUrl: "/benchmarking/wtchart",
-          data: data,
-          success(res) {
-            const data1 = res.data.gaid1;
-            const data2 = res.data.gaid2;
-            const chartData = [
-              {
-                indicator: [
-                  "平均切入风速",
-                  "性能损失电量",
-                  "拟合优度",
-                  "功率一致性系数",
-                  "利用小时",
-                  "设备可利用率",
-                  "等效可利用系数",
-                  "有效风时数",
-                  "平均风速",
-                  "静风频率",
-                ],
-                data: [],
-              },
-            ];
-            if (data1) {
-              chartData[0].data.push(that.getChartData(data1));
+        api.levelAssessmentComparison(data).then((res) => {
+          this.dialogData1 = res.data.data;
+          // 图表
+          let index = 0;
+          let data1 = [];
+          let data2 = [];
+          for (const key in res.data.charts) {
+            switch (index) {
+              case 0:
+                data1 = this.getChartData(key, res.data.charts);
+                index++;
+                break;
+              case 1:
+                data2 = this.getChartData(key, res.data.charts);
+                break;
             }
-            if (data2) {
-              chartData[0].data.push(that.getChartData(data2));
-            }
-            that.dialogData2 = chartData;
-          },
+          }
+          const chartData = [
+            {
+              indicator: [
+                "平均切入风速",
+                "性能损失电量",
+                "拟合优度",
+                "功率一致性系数",
+                "利用小时",
+                "设备可利用率",
+                "等效可利用系数",
+                "有效风时数",
+                "平均风速",
+                "静风频率",
+              ],
+              data: [],
+            },
+          ];
+          if (data1) {
+            chartData[0].data.push(data1);
+          }
+          if (data2) {
+            chartData[0].data.push(data2);
+          }
+          this.dialogData2 = chartData;
         });
       }
       this.clearCheckBox();
     },
-    getChartData(resData) {
+    getChartData(key, data) {
       const chartData = {};
       const rowMap = {};
+      let resData = data[key];
       resData.forEach(function (rowData, index) {
-        rowMap[rowData["name"]] = rowData["data1"];
+        rowMap[rowData["target"]] = rowData["data"];
       });
-      chartData["name"] = resData[resData.length - 1]["name"];
+      chartData["name"] = key;
       chartData["value"] = [];
       chartData["value"].push(rowMap["平均切入风速"]);
       chartData["value"].push(rowMap["性能损失电量"]);

+ 22 - 22
src/views/layout/Menu.vue

@@ -225,11 +225,11 @@ export default {
                   icon: "svg-wind-site",
                   path: "/decision/totalPowerRank",
                 },
-                {
-                  text: "报警排行",
-                  icon: "svg-wind-site",
-                  path: "/decision/warningRank",
-                },
+                // {
+                //   text: "报警排行",
+                //   icon: "svg-wind-site",
+                //   path: "/decision/warningRank",
+                // },
               ],
             },
             {
@@ -761,23 +761,23 @@ export default {
           id: "others",
           text: "其他",
           data: [
-            {
-              text: "统计分析",
-              icon: "svg-统计分析",
-              path: "/others/tjfx",
-              children: [
-                {
-                  text: "统计分析",
-                  icon: "svg-matrix",
-                  path: "/others/tjfx",
-                },
-                {
-                  text: "表底值查询",
-                  icon: "svg-matrix",
-                  path: "/others/bdzcx",
-                },
-              ],
-            },
+            // {
+            //   text: "统计分析",
+            //   icon: "svg-统计分析",
+            //   path: "/others/tjfx",
+            //   children: [
+            //     {
+            //       text: "统计分析",
+            //       icon: "svg-matrix",
+            //       path: "/others/tjfx",
+            //     },
+            //     {
+            //       text: "表底值查询",
+            //       icon: "svg-matrix",
+            //       path: "/others/bdzcx",
+            //     },
+            //   ],
+            // },
             {
               text: "报表管理",
               icon: "svg-报表管理",

+ 42 - 79
src/views/powerRank/index.vue

@@ -2,7 +2,7 @@
   <div class="draught-fan-list">
     <div class="query mg-b-8">
       <div class="query-items">
-        <div class="query-item">
+        <!-- <div class="query-item">
           <div class="lable">类型:</div>
           <div class="search-input">
             <el-select
@@ -20,7 +20,7 @@
               />
             </el-select>
           </div>
-        </div>
+        </div> -->
         <div class="query-item">
           <div class="lable">场站:</div>
           <div class="search-input">
@@ -82,27 +82,25 @@ import api from "@api/economic/index.js";
 export default {
   // 名称
   name: "cutAnalyse",
-
   // 使用组件
   components: {
     ComTable,
   },
-
   // 数据
   data() {
     const that = this;
     return {
       isAsc: "asc",
-      typeArray: [
-        {
-          id: "-1",
-          name: "风场",
-        },
-        {
-          id: "-2",
-          name: "光伏电站",
-        },
-      ],
+      // typeArray: [
+      //   {
+      //     id: "-1",
+      //     name: "风场",
+      //   },
+      //   {
+      //     id: "-2",
+      //     name: "光伏电站",
+      //   },
+      // ],
       typeId: "-1",
       wpArray: [],
       wpId: "",
@@ -115,14 +113,14 @@ export default {
         column: [
           {
             name: "风场",
-            field: "windfarm",
+            field: "wpname",
             is_num: false,
             is_light: false,
             sortable: true,
           },
           {
             name: "风机",
-            field: "windturbine",
+            field: "wtname",
             is_num: false,
             is_light: false,
             sortable: true,
@@ -157,7 +155,7 @@ export default {
           },
           {
             name: "平均效率",
-            field: "generatingCapacity",
+            field: "rankdata",
             is_num: false,
             is_light: false,
             sortable: true,
@@ -172,25 +170,12 @@ export default {
   methods: {
     // 请求服务
     requestData() {
-      api.powercompareWindfarmAllAjax({
-         type: this.typeId,
-      }).then((res) => {
-      this.allWpArray = res.data;
+      api
+        .benchmarkingWplist({})
+        .then((res) => {
+          this.allWpArray = res.data;
           this.renderWprray();
-      });
-
-      // let that = this;
-      // that.API.requestData({
-      //   method: "GET",
-      //   subUrl: "powercompare/windfarmAllAjax",
-      //   data: {
-      //     type: that.typeId,
-      //   },
-      //   success(res) {
-      //     that.allWpArray = res.data;
-      //     that.renderWprray();
-      //   },
-      // });
+        });
     },
 
     renderWprray() {
@@ -200,10 +185,6 @@ export default {
           if (ele.id.indexOf("FDC") !== -1) {
             wpArray.push(ele);
           }
-        } else {
-          if (ele.id.indexOf("GDC") !== -1) {
-            wpArray.push(ele);
-          }
         }
       });
       this.wpId = wpArray[0].id;
@@ -218,48 +199,30 @@ export default {
           msg: "类型与日期不可为空",
         });
       } else {
-        api.leaderboardLoadfactortoplist({
-          wpId: this.wpId,
-            type: this.typeId,
-            isAsc: this.isAsc,
+        api
+          .leaderboardLoadfactortoplist({
+            wpId: this.wpId,
+            isAsc: "",
             beginDate: this.beginDate,
             endDate: this.endDate,
-            orderByColumn: "",
-      }).then((res) => {
-         res.data.forEach((ele) => {
-              ele.beginDate = new Date(ele.beginDate).formatDate("yyyy-MM-dd");
-              ele.endDate = new Date(ele.beginDate).formatDate("yyyy-MM-dd");
-            });
-            res.data.sort((a, b) => {
-              return b.power - a.power;
-            });
-            this.tableData.data = res.data;
-      });
-
-
-
-        // that.API.requestData({
-        //   method: "POST",
-        //   subUrl: "leaderboard/loadfactortoplist",
-        //   data: {
-        //     wpId: that.wpId,
-        //     type: that.typeId,
-        //     isAsc: that.isAsc,
-        //     beginDate: that.beginDate,
-        //     endDate: that.endDate,
-        //     orderByColumn: "",
-        //   },
-        //   success(res) {
-        //     res.data.forEach((ele) => {
-        //       ele.beginDate = new Date(ele.beginDate).formatDate("yyyy-MM-dd");
-        //       ele.endDate = new Date(ele.beginDate).formatDate("yyyy-MM-dd");
-        //     });
-        //     res.data.sort((a, b) => {
-        //       return b.power - a.power;
-        //     });
-        //     that.tableData.data = res.data;
-        //   },
-        // });
+            orderby: "",
+          })
+          .then((res) => {
+            if (res.data) {
+              res.data.forEach((ele) => {
+                ele.beginDate = new Date(ele.beginDate).formatDate(
+                  "yyyy-MM-dd"
+                );
+                ele.endDate = new Date(ele.endDate).formatDate("yyyy-MM-dd");
+                ele.speed = ele.speed.toFixed(2);
+                ele.power = ele.power.toFixed(2);
+              });
+              res.data.sort((a, b) => {
+                return b.power - a.power;
+              });
+              this.tableData.data = res.data;
+            }
+          });
       }
     },
 

+ 66 - 165
src/views/totalPowerRank/index.vue

@@ -3,33 +3,12 @@
     <div class="query mg-b-8">
       <div class="query-items">
         <div class="query-item">
-          <div class="lable">类型:</div>
-          <div class="search-input">
-            <el-select
-              v-model="wpIps"
-              clearable
-              placeholder="请选择"
-              popper-class="select"
-              @change="renderWprray"
-            >
-              <el-option
-                v-for="item in typeArray"
-                :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-select
               v-model="wpId"
               clearable
-              multiple
-              collapse-tags
-              placeholder="请选择"
+              placeholder="请选择 "
               popper-class="select"
             >
               <el-option
@@ -46,7 +25,7 @@
           <div class="search-input">
             <el-date-picker
               v-model="beginDate"
-              type="month"
+              type="date"
               value-format="YYYY-MM-DD"
               placeholder="选择日期"
               popper-class="date-select"
@@ -59,7 +38,7 @@
           <div class="search-input">
             <el-date-picker
               v-model="endDate"
-              type="month"
+              type="date"
               value-format="YYYY-MM-DD"
               placeholder="选择日期"
               popper-class="date-select"
@@ -77,44 +56,42 @@
     </div>
   </div>
 </template>
-
 <script>
 import ComTable from "@com/coms/table/table.vue";
 import api from "@api/economic/index.js";
 export default {
   // 名称
   name: "cutAnalyse",
-
   // 使用组件
   components: {
     ComTable,
   },
-
   // 数据
   data() {
     return {
       isAsc: "asc",
+      typeId: "-1",
       typeArray: [],
       wpIps: "",
       wpArray: [],
-      wpId: [],
+      wpId: "",
       beginDate: new Date(new Date().getTime() - 3600 * 1000 * 24).formatDate(
-        "yyyy-MM"
+        "yyyy-MM-dd"
       ),
-      endDate: new Date().formatDate("yyyy-MM"),
+      endDate: new Date().formatDate("yyyy-MM-dd"),
       dialogShow: false,
       tableData: {
         column: [
           {
             name: "风场",
-            field: "windfarm",
+            field: "wpname",
             is_num: false,
             is_light: false,
             sortable: true,
           },
           {
             name: "风机",
-            field: "windturbine",
+            field: "wtname",
             is_num: false,
             is_light: false,
             sortable: true,
@@ -142,7 +119,7 @@ export default {
           },
           {
             name: "发电量(万kwh)",
-            field: "generatingCapacity",
+            field: "rankdata",
             is_num: false,
             is_light: false,
             sortable: true,
@@ -157,102 +134,47 @@ export default {
   methods: {
     // 请求服务
     requestData() {
-api.powercompareWindfarmAllAjax({
-          type: this.typeId,
-      }).then((res) => {
-          this.allWpArray = res.data;
-          let fdc = [];
-          let gf = [];
-
-          res.data.forEach((ele) => {
-            if (ele.id.indexOf("FDC") !== -1) {
-              fdc.push(ele.id);
-            } else {
-              gf.push(ele.id);
-            }
-          });
-          this.typeArray = [
-            {
-              id: [].concat(fdc, gf).toString(),
-              name: "全部",
-            },
-            {
-              id: fdc.toString(),
-              name: "风场",
-            },
-            {
-              id: gf.toString(),
-              name: "光伏电站",
-            },
-          ];
-          this.wpIps = [].concat(fdc, gf).toString();
-          this.renderWprray();
+      api.benchmarkingWplist({}).then((res) => {
+        this.allWpArray = res.data;
+        let fdc = [];
+        let gf = [];
+        res.data.forEach((ele) => {
+          if (ele.id.indexOf("FDC") !== -1) {
+            fdc.push(ele.id);
+          }
+          // else {
+          //   gf.push(ele.id);
+          // }
+        });
+        // this.typeArray = [
+        //   {
+        //     id: [].concat(fdc, gf).toString(),
+        //     name: "全部",
+        //   },
+        //   {
+        //     id: fdc.toString(),
+        //     name: "风场",
+        //   },
+        //   {
+        //     id: gf.toString(),
+        //     name: "光伏电站",
+        //   },
+        // ];
+        // this.wpIps = [].concat(fdc, gf).toString();
+        this.renderWprray();
       });
-
-
-      // let that = this;
-      // that.API.requestData({
-      //   method: "GET",
-      //   subUrl: "powercompare/windfarmAllAjax",
-      //   data: {
-      //     type: that.typeId,
-      //   },
-      //   success(res) {
-      //     that.allWpArray = res.data;
-      //     let fdc = [];
-      //     let gf = [];
-
-      //     res.data.forEach((ele) => {
-      //       if (ele.id.indexOf("FDC") !== -1) {
-      //         fdc.push(ele.id);
-      //       } else {
-      //         gf.push(ele.id);
-      //       }
-      //     });
-      //     that.typeArray = [
-      //       {
-      //         id: [].concat(fdc, gf).toString(),
-      //         name: "全部",
-      //       },
-      //       {
-      //         id: fdc.toString(),
-      //         name: "风场",
-      //       },
-      //       {
-      //         id: gf.toString(),
-      //         name: "光伏电站",
-      //       },
-      //     ];
-      //     that.wpIps = [].concat(fdc, gf).toString();
-      //     that.renderWprray();
-      //   },
-      // });
     },
 
     renderWprray() {
       let wpArray = [];
-      if (!this.wpIps) {
-        this.wpIps = []
-          .concat(
-            this.typeArray[1].id.split(","),
-            this.typeArray[2].id.split(",")
-          )
-          .toString();
-      }
       this.allWpArray.forEach((ele) => {
-        if (this.wpIps.indexOf("FDC") !== -1) {
-          if (ele.id.indexOf("FDC") !== -1) {
-            wpArray.push(ele);
-          }
-        } else if (this.wpIps.indexOf("GDC")) {
-          if (ele.id.indexOf("GDC") !== -1) {
-            wpArray.push(ele);
-          }
-        } else {
+        // if (this.typeId === "-1") {
+        if (ele.id.indexOf("FDC") !== -1) {
           wpArray.push(ele);
         }
+        // }
       });
-      this.wpId = this.wpIps ? this.wpIps.split(",") : [];
+      this.wpId = wpArray[0].id;
       this.wpArray = wpArray;
       this.getOutputSpeedList();
     },
@@ -264,51 +186,30 @@ api.powercompareWindfarmAllAjax({
           msg: "日期不可为空",
         });
       } else {
-
-        api.leaderboardTotalPowerCapacityTopList({
-       wpIps: this.wpId.length ? this.wpId.toString() : this.wpIps,
-            isAsc: this.isAsc,
-            beginDate: this.beginDate + "-01",
-            endDate:this.endDate + "-" + (new Date().getDate() < 10? "0" + new Date().getDate(): new Date().getDate()),
-            orderByColumn: "",
-      }).then((res) => {
-      res.data.forEach((ele) => {
-              ele.beginDate = new Date(ele.beginDate).formatDate("yyyy-MM-dd");
-              ele.endDate = new Date(ele.beginDate).formatDate("yyyy-MM-dd");
-			  ele.speed = ele.speed.toFixed(2);
-            });
-            res.data.sort((a, b) => {
-              return b.power - a.power;
-            });
-            this.tableData.data = res.data;
-      });
-
-
-
-
-      //   that.API.requestData({
-      //     method: "GET",
-      //     subUrl: "leaderboard/totalPowerCapacityTopList",
-		  // showLoading: true,
-      //     data: {
-      //       wpIps: that.wpId.length ? that.wpId.toString() : that.wpIps,
-      //       isAsc: that.isAsc,
-      //       beginDate: that.beginDate + "-01",
-      //       endDate:that.endDate + "-" + (new Date().getDate() < 10? "0" + new Date().getDate(): new Date().getDate()),
-      //       orderByColumn: "",
-      //     },
-      //     success(res) {
-      //       res.data.forEach((ele) => {
-      //         ele.beginDate = new Date(ele.beginDate).formatDate("yyyy-MM-dd");
-      //         ele.endDate = new Date(ele.beginDate).formatDate("yyyy-MM-dd");
-			//   ele.speed = ele.speed.toFixed(2);
-      //       });
-      //       res.data.sort((a, b) => {
-      //         return b.power - a.power;
-      //       });
-      //       that.tableData.data = res.data;
-      //     },
-      //   });
+        api
+          .leaderboardTotalPowerCapacityTopList({
+            wpid: this.wpId,
+            isAsc: "",
+            beginDate: this.beginDate,
+            endDate: this.endDate,
+            orderby: "",
+          })
+          .then((res) => {
+            if (res.data) {
+              res.data.forEach((ele) => {
+                ele.beginDate = new Date(ele.beginDate).formatDate(
+                  "yyyy-MM-dd"
+                );
+                ele.endDate = new Date(ele.endDate).formatDate("yyyy-MM-dd");
+                ele.speed = ele.speed.toFixed(2);
+                
+              });
+              res.data.sort((a, b) => {
+                return b.power - a.power;
+              });
+              this.tableData.data = res.data;
+            }
+          });
       }
     },