Browse Source

4-22 场内 场际

zhaomiao 4 years ago
parent
commit
a1e6fe8efc

+ 34 - 6
src/assets/js/benchmarkingSys/innationBenchmarkParticulars.js

@@ -46,6 +46,9 @@ export default {
       return value.toFixed(2)
       }
     },
+    /**
+     * 获取跳转数据
+     */
     created(){
         this.value = this.$route.query.wpId;
         this.timedate[0] = this.$route.query.beginDate;
@@ -53,6 +56,9 @@ export default {
         this.YardTableData();
     },
     methods:{
+        /**
+         * 查询场内风机列表信息
+         */
         queryApData() {
             this.YardTableData();
             if(this.value2 != null || this.value2 != undefined){
@@ -75,9 +81,14 @@ export default {
           this.API.post('/contrast/benchmarkWpInWtList',guilty).then((res) => {
             this.fdcLineData2 = res.data;
             this.loading2=false;
-          })
+          }).catch(error =>{
+            this.$message.error('获取数据失败');
+          });
             }
         },
+        /**
+         * 判断是否选择两个场站
+         */
         queryApDataMx() {
            
            if(this.multipleSelection1.length+this.multipleSelection2.length==2){
@@ -122,7 +133,8 @@ export default {
               
               this.dialogTableVisible = true;
                 this.$nextTick(function() {
-                    this.drawPie('leiDaTu5')
+                    this.ECZM.leida_tc("leiDaTu5" , this.getChartDataValue,this.BASE.getBzDate(new Date(this.wp_n_1.recordDate),0),this.getChartDataValue2,this.BASE.getBzDate(new Date(this.wp_n_2.recordDate),0));
+       
                 })
                 this.$nextTick(function() {
                     this.drawPie2('leiDaTu6')
@@ -130,13 +142,21 @@ export default {
             } 
                 
         },
+        /**
+         * 格式转化(取小数点)
+         */
         filter_fdl(cellValue){
              return parseFloat(cellValue.scadafdl).toFixed(2);
     },
+    /**
+     * 查询场内风机列表信息
+     */
         YardTableData(){
             this.API.get('/powercompare/windfarmAjax').then((res) => {
               this.options = res.data;
-            })
+            }).catch(error =>{
+                this.$message.error('获取数据失败');
+              });
             this.wpId = this.$route.query.wpId;
             if(this.timedate == ''){
                 this.beginDate = this.$route.query.beginDate;
@@ -160,7 +180,9 @@ export default {
           this.API.post('/contrast/benchmarkWpInWtList',guilty).then((res) => {
             this.fdcLineData = res.data;
             this.loading = false;
-          })
+          }).catch(error =>{
+            this.$message.error('获取数据失败');
+          });
         },
         headStyle() {
 			    return "text-align:left"
@@ -192,6 +214,9 @@ export default {
           }
           this.YardTableData();
         },
+        /**
+         * 日期格式转换
+         */
         filter_date(cellValue) {
             let date = new Date(cellValue.recordDate);
             return this.BASE.getBzDate(date,0);
@@ -253,7 +278,7 @@ export default {
             charts.setOption(option, true);
             
           },
-          drawPie2() {
+        drawPie2() {
             let charts2 = echarts.getInstanceByDom(document.getElementById("leiDaTu6")); //有的话就获取已有echarts实例的DOM节点。
             if (charts2 == null) { // 如果不存在,就进行初始化。
                 charts2 = echarts.init(document.getElementById("leiDaTu6"),'light');
@@ -327,7 +352,10 @@ export default {
                   charts2.setOption(option2, true);
             
           },
-          goReturn(){
+          /**
+           * 返回按钮
+           */
+        goReturn(){
             this.$router.push('/benchmark_International')
           },
           }

+ 32 - 2
src/assets/js/benchmarkingSys/internationalBenchmark.js

@@ -42,6 +42,9 @@ export default {
     changeFun(val) {
       this.selectrowdate = val;
     },
+    /**
+     * 日期转换
+     */
     filter_date(cellValue) {
       let date = new Date(cellValue.recordDate);
 
@@ -59,9 +62,15 @@ export default {
     queryApData() {
       this.Inquire_tableDate();
     },
+    /**
+     * 转换格式(去小数点)
+     */
     simplification(cellValue){
       return parseFloat(cellValue.fdl).toFixed(2);
     },
+    /**
+     * 详情跳转
+     */
     handleEdit(a, b) {
       this.wpId = [];
       this.lineDataOption = [];
@@ -98,15 +107,23 @@ export default {
         });
       }
     },
+    /**
+     * 对标分析
+     */
     queryApDataMx() {
       this.dialogTableVisible = true;
       this.$nextTick(function () {
-        this.drawPie("leiDaTu");
+        this.ECZM.leida_tc("leiDaTu" , this.sortInOrder,this.fdcName1,this.sortInOrderTop,this.fdcName2);
+        
+
       });
       this.$nextTick(function () {
         this.drawPie2("leiDaTu2");
       });
     },
+    /**
+     * 数据格式转换
+     */
     handleSelectionChange(val) {
       this.sortInOrder = [];
       this.sortInOrderTop = [];
@@ -222,9 +239,15 @@ export default {
     },
     handleCurrentChange(val) {
     },
+    /**
+     * 分页功能
+     */
     handleSizeChange(val) {
       this.pagesize = val;
     },
+    /**
+     * 分页功能
+     */
     changeTableSort(column) {
       this.orderByColumn = column.prop;
       if (column.order == "descending") {
@@ -234,6 +257,9 @@ export default {
       }
       this.Inquire_tableDate();
     },
+    /**
+     * 查询场际对标列表信息
+     */
     Inquire_tableDate() {
       var newData = new Date();
        this.timedate[0] = this.BASE.getBzDate(newData.getTime(),-1);
@@ -241,6 +267,8 @@ export default {
       let that = this;
       this.API.get("/powercompare/windfarmAjax").then((res) => {
         that.FClist = res.data;
+      }).catch(error =>{
+        this.$message.error('获取数据失败');
       });
       if (this.timedate == "") {
         this.timedate[0] = "2021-01-01";
@@ -265,6 +293,8 @@ export default {
           that.gridData = res.data;
           that.getPackageData(that.gridData);
           that.getPackageData2(that.gridData);
+        }).catch(error =>{
+          this.$message.error('获取数据失败');
         });
     },
     drawPie() {
@@ -493,7 +523,7 @@ export default {
             }
             this.getChartDataImport2();
         },
-        getChartDataImport2(){
+    getChartDataImport2(){
             var charts =echarts.init(document.getElementById("chartHistogram"));
             let option = {
             title: {

+ 6 - 2
src/assets/js/benchmarkingSys/yardBenchmark.js

@@ -42,8 +42,8 @@ export default {
       this.dialogTableVisible = true;
       this.check_wpid();
       this.$nextTick(function () {
-        this.drawleidatu();
-        this.drawhistogram_n();
+        this.ECZM.leida_tc("leidatu" , this.getChartDataValue,this.BASE.getBzDate(new Date(this.wp_n_1.recordDate),0),this.getChartDataValue2,this.BASE.getBzDate(new Date(this.wp_n_2.recordDate),0));
+        this.ECZM.bar_tc("histogram_n" , this.wp_n_1 , this.wp_n_2);
       });
     },
     headStyle() {
@@ -180,6 +180,8 @@ export default {
        this.endDate = this.BASE.getBzDate(newData,0);
        this.API.get("powercompare/windfarmAjax?").then((res) => {
         that.FClist = res.data;
+      }).catch(error =>{
+        this.$message.error('获取数据失败');
       });
     },
     /**
@@ -296,6 +298,8 @@ export default {
             data: this.histogram.slss,
           },
         ],this.histogram.date);
+      }).catch(error =>{
+        this.$message.error('获取数据失败');
       });
     },
     /**

+ 94 - 62
src/assets/js/benchmarkingSys/yardBenchmarkParticulars.js

@@ -26,6 +26,9 @@ export default {
     };
   },
   filters: {
+    /**
+     * 改变格式(取小数点)
+     */
     rounding(value) {
       return value.toFixed(2);
     },
@@ -37,10 +40,14 @@ export default {
     this.queryApData();
   },
   methods: {
+    /**
+     * 获取当前id
+     */
 queryApData() {
     this.value = this.$route.query.wpId;
     this.YardTableData();
   },
+
   queryApDataMx() {
     this.dialogTableVisible = true;
 
@@ -153,15 +160,21 @@ queryApData() {
       });
     }
     this.$nextTick(function () {
-      this.drawPie("leiDaTu3");
-    });
-    this.$nextTick(function () {
       this.drawPie2("leiDaTu4");
+      this.ECZM.leida_tc("leiDaTu3" , this.sortInOrder,this.fdcName1,this.sortInOrderTop,this.fdcName2);
+    //this.ECZM.bar_tc("histogram_n" , this.wp_n_1 , this.wp_n_2);
+      
     });
   },
+  /**
+   * 改变格式去小数点
+   */
   filter_fdl(cellValue) {
     return parseFloat(cellValue.scadafdl).toFixed(2);
   },
+  /**
+   * 判断选中条数是否等于2
+   */
   ApDataMxcheck() {
     if (this.multipleSelection.length == 2) {
       this.queryApDataMx();
@@ -173,11 +186,16 @@ queryApData() {
       return;
     }
   },
+  /**
+   * 查询场内风机列表信息
+   */
   YardTableData() {
     let that = this;
     Object.assign(this.$data.fdcLineData, this.$options.data().fdcLineData);
     this.API.get("/powercompare/windfarmAjax").then((res) => {
       this.options = res.data;
+    }).catch(error =>{
+      this.$message.error('获取数据失败');
     });
     this.wpId = this.$route.query.wpId;
     if (this.timedate == "") {
@@ -202,11 +220,16 @@ queryApData() {
     this.API.post("/contrast/benchmarkWpInWtList", guilty).then((res) => {
       this.fdcLineData = res.data;
       this.loading=false;
+    }).catch(error =>{
+      this.$message.error('获取数据失败');
     });
   },
   headStyle() {
     return "text-align:center";
   },
+  /**
+   * 选中表格
+   */
   handleSelectionChange(val) {
     this.sortInOrder = [];
     this.sortInOrderTop = [];
@@ -224,69 +247,72 @@ queryApData() {
     }
     this.YardTableData();
   },
+  /**
+   * 时间格式转化
+   */
   filter_date(cellValue) {
     let date = new Date(cellValue.recordDate);
     return this.BASE.getBzDate(date,0);
   },
-  drawPie() {
-    var charts;
-    if (charts != null && charts != "" && charts != undefined) {
-      charts.dispose();
-    }
-    charts = echarts.init(document.getElementById("leiDaTu3"));
-    let option = {
-      title: {
-        // text: '对标排名分析',
-        left: "center",
-      },
-      tooltip: {},
-      // legend: {
-      //     data: ['预算分配(Allocated Budget)', '实际开销(Actual Spending)'],
-      //     left: 'right'
-      // },
-      radar: {
-        // shape: 'circle',
-        name: {
-          textStyle: {
-            color: "#fff",
-            backgroundColor: "#999",
-            borderRadius: 3,
-            padding: [3, 5],
-          },
-        },
-        indicator: [
-          { name: "风能利用率", max: 150 },
-          { name: "消缺及时率", max: 150 },
-          { name: "状态转换率", max: 150 },
-          { name: "复位及时率", max: 150 },
-          { name: "受累损失率", max: 150 },
-          { name: "性能损失率", max: 150 },
-          { name: "弃风率", max: 150 },
-          { name: "检修损失率", max: 150 },
-          { name: "故障损失率", max: 150 },
-        ],
-      },
-      series: [
-        {
-          name: "预算 vs 开销(Budget vs spending)",
-          type: "radar",
-          // areaStyle: {normal: {}},
-          data: [
-            {
-              value: this.sortInOrder,
-              name: this.fdcName1,
-            },
-            {
-              value: this.sortInOrderTop,
-              name: this.fdcName2,
-            },
-          ],
-        },
-      ],
-    };
-    charts.clear();
-    charts.setOption(option);
-  },
+  // drawPie() {
+  //   var charts;
+  //   if (charts != null && charts != "" && charts != undefined) {
+  //     charts.dispose();
+  //   }
+  //   charts = echarts.init(document.getElementById("leiDaTu3"));
+  //   let option = {
+  //     title: {
+  //       // text: '对标排名分析',
+  //       left: "center",
+  //     },
+  //     tooltip: {},
+  //     // legend: {
+  //     //     data: ['预算分配(Allocated Budget)', '实际开销(Actual Spending)'],
+  //     //     left: 'right'
+  //     // },
+  //     radar: {
+  //       // shape: 'circle',
+  //       name: {
+  //         textStyle: {
+  //           color: "#fff",
+  //           backgroundColor: "#999",
+  //           borderRadius: 3,
+  //           padding: [3, 5],
+  //         },
+  //       },
+  //       indicator: [
+  //         { name: "风能利用率", max: 150 },
+  //         { name: "消缺及时率", max: 150 },
+  //         { name: "状态转换率", max: 150 },
+  //         { name: "复位及时率", max: 150 },
+  //         { name: "受累损失率", max: 150 },
+  //         { name: "性能损失率", max: 150 },
+  //         { name: "弃风率", max: 150 },
+  //         { name: "检修损失率", max: 150 },
+  //         { name: "故障损失率", max: 150 },
+  //       ],
+  //     },
+  //     series: [
+  //       {
+  //         name: "预算 vs 开销(Budget vs spending)",
+  //         type: "radar",
+  //         // areaStyle: {normal: {}},
+  //         data: [
+  //           {
+  //             value: this.sortInOrder,
+  //             name: this.fdcName1,
+  //           },
+  //           {
+  //             value: this.sortInOrderTop,
+  //             name: this.fdcName2,
+  //           },
+  //         ],
+  //       },
+  //     ],
+  //   };
+  //   charts.clear();
+  //   charts.setOption(option);
+  // },
   drawPie2() {
     
     var charts2;
@@ -365,9 +391,15 @@ queryApData() {
     charts2.clear();
     charts2.setOption(option2);
   },
+  /**
+   * 返回按钮
+   */
   goReturn() {
     this.$router.push("/benchmark_Venue");
   },
+  /**
+   * 导出表格
+   */
   toExcel() {
     excelHelper.exportExcel("fdcLineData","损失率对标列表",".xls",true);
   },

+ 12 - 0
src/router/zm.js

@@ -30,5 +30,17 @@ export default [
   { // 项目对标详情
     path:'/projectBenchmarkParticulars',
     component: r => require.ensure([], () => r(require('@views/benchmarkingSys/projectBenchmarkParticulars')), 'benchmarkingSys')
+  },
+  { // 性能对标
+    path:'/propertBenchmark',
+    component: r => require.ensure([], () => r(require('@views/benchmarkingSys/propertBenchmark')), 'benchmarkingSys')
+  },
+  { // 性能对标详情
+    path:'/propertBenchmarkParticulars',
+    component: r => require.ensure([], () => r(require('@views/benchmarkingSys/propertBenchmarkParticulars')), 'benchmarkingSys')
+  },
+  { // 单机横向对比
+    path:'/singleTransverseBenchmark',
+    component: r => require.ensure([], () => r(require('@views/benchmarkingSys/singleTransverseBenchmark')), 'benchmarkingSys')
   }
 ]

+ 495 - 1
src/tools/echartsToolzm.js

@@ -1,4 +1,5 @@
 import EC from 'echarts'
+import BASE from '@tools/base';
 const color = ["#00FFF0","#014EB5","#A800FF","#e82edb","#B5454C","#443bff","#e8cb25","#3dffb0","#e8a425","#ff7aab","#e84b1e","#552ce2","#ffae21","#e8861e","#d441ff","#35e8e4","#9c7aff","#e86fd8","#ffee38"];
 
 /*
@@ -78,9 +79,502 @@ export function getBar_fdd(id, data , xdata) {
   };
   myChart.setOption(option, true);
 }
+/**
+ * 
+ * @param {id名称} id 
+ * @param {第一台风机数据} value1 
+ * @param {第一台风机名字} name1 
+ * @param {第二台风机数据} value2 
+ * @param {第二台风机名字} name2 
+ * @returns 
+ */
+export function leida_tc(id , value1 , name1 , value2 , name2) {
+  if(value1 === undefined || value2 === undefined){
+    message.error("没有找到报表数据,请检查!");
+    return;
+  }
+  var myChart = EC.init(document.getElementById(id));
+  var option;
+
+      option = {
+        title: {
+          text: "对标排名分析",
+          left: 400,
+          top: -5,
+          textStyle: {
+            fontSize: 13,
+          },
+        },
+        grid: {
+          top: "10%",
+          left: "10%",
+          right: "10%",
+          bottom: "0",
+        },
+        tooltip: {},
+        legend: {
+          orient: "vertical",
+          x: "left", //可设定图例在左、右、居中
+          y: "0", //可设定图例在上、下、居中
+          padding: [0, 50, 0, 0],
+        },
+        radar: {
+          // shape: 'circle',
+          name: {
+            textStyle: {
+              color: "#fff",
+              backgroundColor: "#999",
+              borderRadius: 3,
+              padding: [3, 5],
+            },
+          },
+          indicator: [
+            { name: "风能利用率", max: 100 },
+            { name: "故障损失率", max: 100 },
+            { name: "检修损失率", max: 100 },
+            { name: "弃风率", max: 100 },
+            { name: "性能损失率", max: 100 },
+            { name: "受累损失率", max: 100 },
+            { name: "复位及时率", max: 100 },
+            { name: "状态转换率", max: 100 },
+            { name: "消缺及时率", max: 100 },
+          ],
+        },
+        series: [
+          {
+            name: "预算 vs 开销(Budget vs spending)",
+            type: "radar",
+            // areaStyle: {normal: {}},
+            data: [
+              {
+                value: value1,
+                name: name1,
+              },
+              {
+                value: value2,
+                name: name2,
+              },
+            ],
+          },
+        ],
+      };
+      
+  myChart.setOption(option, true);
+}
+/**
+ * 
+ * @param {id名称} id 
+ * @param {第一台风机数据} value1 
+ * @param {第二台风机数据} value2 
+ * @returns 
+ */
+export function bar_tc(id , value1 , value2) {
+  if(value1 === undefined || value2 === undefined){
+    message.error("没有找到报表数据,请检查!");
+    return;
+  }
+  var myChart = EC.init(document.getElementById(id));
+  var option;
+  option = {
+    tooltip: {
+      trigger: "axis",
+      axisPointer: {
+        type: "cross",
+        crossStyle: {
+          color: "#999",
+        },
+      },
+    },
+    title: {
+      text: "损失电量分析",
+      left: 100,
+      top: 8,
+      textStyle: {
+        fontSize: 13,
+      },
+    },
+    grid: {
+      top: "90",
+      left: "10%",
+      right: "10%",
+      bottom: "30",
+    },
+    legend: {
+      orient: "vertical",
+      x: "right", //可设定图例在左、右、居中
+      y: 0, //可设定图例在上、下、居中
+      padding: [0, 50, 200, 0],
+      data: [
+        "限电损失电量(单位:万kwh)",
+        "故障损失电量(单位:万kwh)",
+        "检修损失电量(单位:万kwh)",
+        "性能损失电量(单位:万kwh)",
+        "受累损失电量(单位:万kwh)",
+      ],
+    },
+    xAxis: [
+      {
+        type: "category",
+        data: [
+          BASE.getBzDate(new Date(value1.recordDate),0),
+          BASE.getBzDate(new Date(value2.recordDate),0),
+        ],
+        axisPointer: {
+          type: "shadow",
+        },
+      },
+    ],
+    yAxis: [
+      {
+        type: "value",
+        name: "电量",
+
+        interval: 50,
+        axisLabel: {
+          formatter: "{value} 万kw",
+        },
+      },
+    ],
+    series: [
+      {
+        name: "限电损失电量(单位:万kwh)",
+        type: "bar",
+        yAxisIndex: 0,
+        data: [value1.xdss, value2.xdss],
+      },
+      {
+        name: "故障损失电量(单位:万kwh)",
+        type: "bar",
+        yAxisIndex: 0,
+        data: [value1.zzss, value2.gzss],
+      },
+      {
+        name: "检修损失电量(单位:万kwh)",
+        type: "bar",
+        yAxisIndex: 0,
+        data: [value1.jxss, value2.jxss],
+      },
+      {
+        name: "性能损失电量(单位:万kwh)",
+        type: "bar",
+        yAxisIndex: 0,
+        data: [value1.xnss, value2.xnss],
+      },
+      {
+        name: "受累损失电量(单位:万kwh)",
+        type: "bar",
+        yAxisIndex: 0,
+        data: [value1.slss, value2.slss],
+      },
+    ],
+  };
+
+    
+      
+  myChart.setOption(option, true);
+}
+/**
+ * 
+ * @param {id名称} id 
+ * @param {数据} value 
+ * @returns 
+ */
+export function bar_tc_2(id  , value) {
+  if(value === undefined){
+    message.error("没有找到报表数据,请检查!");
+    return;
+  }
+  var myChart = EC.init(document.getElementById(id));
+  let option = {
+  legend: {
+    orient: "vertical",
+    left: "right",
+  },
+  tooltip: {},
+  dataset: {
+    dimensions: [
+      "product",
+      "限电损失电量单位:万KWh",
+      "故障损失电量单位:万KWh",
+      "检修损失电量单位:万KWh",
+      "性能损失电量单位:万KWh",
+      "受累损失电量单位:万KWh",
+    ],
+    source: value,
+  },
+  xAxis: { type: "category" },
+  yAxis: {},
+  // Declare several bar series, each will be mapped
+  // to a column of dataset.source by default.
+  series: [
+    {
+      // barGap:'100%',/*多个并排柱子设置柱子之间的间距*/
+      type: "bar",
+      barWidth: 30,
+      itemStyle: {
+        normal: {
+          color: "#D201D8",
+        },
+      },
+    },
+    {
+      type: "bar",
+      barWidth: 30,
+      itemStyle: {
+        normal: {
+          color: "#FD0100",
+        },
+      },
+    },
+    {
+      type: "bar",
+      barWidth: 30,
+      itemStyle: {
+        normal: {
+          color: "#FF7B16",
+        },
+      },
+    },
+    {
+      type: "bar",
+      barWidth: 30,
+      itemStyle: {
+        normal: {
+          color: "#8085E9",
+        },
+      },
+    },
+    {
+      type: "bar",
+      barWidth: 30,
+      itemStyle: {
+        normal: {
+          color: "#A6A6A6",
+        },
+      },
+    },
+  ],
+};
+myChart.setOption(option, true);
+}
+/**
+ * 用在单机饱和度分体  表格内雷达图
+ * @param {id名称} id 
+ * @param {雷达图数据} value 
+ * @param {雷达图名称} name 
+ * @returns 
+ */
+export function leida_djbhd(id  , value , name) {
+  if(value === undefined){
+    message.error("没有找到报表数据,请检查!");
+    return;
+  }
+  var myChart = EC.init(document.getElementById(id));
+  myChart.resize({ height: 300 });
+  let option = {
+  tooltip: {},
+  legend: {
+    top: "93%",
+    left: "10%",
+  },
+  tooltip: {
+    triggerOn: "none",
+    alwaysShowContent: true,
+    position: function (pt) {
+      return [pt[0], 130];
+    },
+  },
+  radar: {
+    name: {
+      textStyle: {
+        color: "#fff",
+        backgroundColor: "#999",
+        borderRadius: 3,
+        padding: [3, 5],
+      },
+    },
+    indicator: [
+      { name: "北", max: 99 },
+      { name: "北北东", max: 99 },
+      { name: "北东", max: 99 },
+      { name: "东北东", max: 99 },
+      { name: "东", max: 99 },
+      { name: "东南东", max: 99 },
+      { name: "南东", max: 99 },
+      { name: "南南东", max: 99 },
+      { name: "南", max: 99 },
+      { name: "南南西", max: 99 },
+      { name: "南西", max: 99 },
+      { name: "西南西", max: 99 },
+      { name: "西", max: 99 },
+      { name: "西北西", max: 99 },
+      { name: "北西", max: 99 },
+      { name: "北北西", max: 99 },
+    ],
+  },
+  series: [
+    {
+      type: "radar",
+      // areaStyle: {normal: {}},
+      data: [
+        {
+          value: value,
+          name: name,
+          label: {
+            show: true,
+            position: "insideBottomRight",
+            distance: 14.5,
+            //rotate: -45,
+            offset: [11, 0],
+            formatter:function(params){
+              let list = ["北","北北东","北东","东北东","东","东南东","南东","南南东","南","南南西","南西","西南西","西","西北西","北西","北北西"]
+              if(params.value<10){
+                return ''
+              }else{
+                  return list[params.dimensionIndex]+':'+params.value;
+              }
+            }
+          },
+          areaStyle: {
+            opacity: 0.9,
+            color: new EC.graphic.RadialGradient(0.5, 0.5, 1, [
+              {
+                color: "#B8D3E4",
+                offset: 0,
+              },
+              {
+                color: "#72ACD1",
+                offset: 1,
+              },
+            ]),
+          },
+        },
+      ],
+      itemStyle: { normal: { label: { show: true } } },
+    },
+  ],
+  tooltip: {
+    show:false,
+    position: function (p) {
+      //其中p为当前鼠标的位置
+      return [p[0] + 10, p[1] - 100];
+    },
+    // formatter: function (params) {
+    //   //其中p为当前鼠标的位置
+    //   debugger
+    //    let fanhui = [];
+    //    let str ='';
+    //    let list = ["北","北北东","北东","东北东","东","东南东","南东","南南东","南","南南西","南西","西南西","西","西北西","北西","北北西"]
+    //    for(let i=1;i<Object.keys(params.value).length;i++){
+    //           if(params.value[i]>10){
+    //             fanhui.push(params.value[i]+':'+list[i]);
+    //           }
+    //    }
+    //    for(let j = 1 ;j<fanhui.length;j++){
+    //       str.concat(fanhui[j]);
+    //    }
+    //    return str;
+    // },
+    textStyle: {
+      fontWeight: "16px",
+      fontSize: 16,
+      lineHeight: 0,
+    },
+  },
+};
+
+myChart.setOption(option, true);
+}
+/**
+ * 
+ * @param {id名称} id 
+ * @param {风机集合} fj 
+ * @param {曲线数据} lineDate 
+ * @returns 
+ */
+export function bar_djbhd(id  , fj , lineDate) {
+  if(lineDate === undefined){
+    message.error("没有找到报表数据,请检查!");
+    return;
+  }
+  var myChart = EC.init(document.getElementById(id));
+  let option = {
+  title: {
+    text: "日功率曲线",
+  },
+  tooltip: {
+    trigger: "axis",
+  },
+  legend: {
+    data: fj,
+  },
+  grid: {
+    left: "3%",
+    right: "4%",
+    bottom: "3%",
+    containLabel: true,
+  },
+  toolbox: {
+    feature: {
+      saveAsImage: {},
+    },
+  },
+  xAxis: {
+    type: "category",
+    boundaryGap: false,
+
+    data: lineDate.speed,
+  },
+  yAxis: {
+    type: "value",
+  },
+  series: [
+    {
+      name: fj[0],
+      type: "line",
+      stack: "总量",
+      smooth: true,
+      data: lineDate.value1,
+    },
+    {
+      name: fj[1],
+      type: "line",
+      stack: "总量",
+      smooth: true,
+      data: lineDate.value2,
+    },
+    {
+      name: fj[2],
+      type: "line",
+      stack: "总量",
+      smooth: true,
+      data: lineDate.value3,
+    },
+    {
+      name: fj[3],
+      type: "line",
+      stack: "总量",
+      smooth: true,
+      data: lineDate.value3,
+    },
+    {
+      name: fj[4],
+      type: "line",
+      stack: "总量",
+      smooth: true,
+      data: lineDate.value4,
+    },
+  ],
+};
+myChart.setOption(option, true);
+}
 
 export default {
   getBar_fdd,
-
+  leida_tc,
+  bar_tc,
+  bar_tc_2,
+  leida_djbhd,
+  bar_djbhd,
   color,
 }