廖井涛
2024-03-04 2cf22385d45af4427b354e383243155ef35b70a5
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
Vue.prototype.global={
  polling:null,
  pollingIndex:0,
  timer:5000,//触发定时器时间
  errorFlag:0,
  val: {
    title:{
      text:'',
      left:'center'
    },
    tooltip: {
      trigger: 'axis',
      axisPointer: {
        type: 'shadow'
      }
    },
    grid: {
      left: '3%',
      right: '4%',
      bottom: '3%',
      containLabel: true
    },
    xAxis: [{
      type: 'category',
      data: [],
      axisLine: {
        lineStyle: {
          color: 'rgb(30, 144, 255)'
        }
      },
      axisLabel: {
        color: 'rgb(30, 144, 255)'
      },
      splitLine: {
        lineStyle: {
          color: 'rgb(30, 144, 255)',
          type: 'dashed'
        }
      }
    }],
    yAxis: [{
        type: "value",
        name: "能耗",
        nameTextStyle: {
          color: "rgb(30, 144, 255)",
          fontSize: 12,
          padding: [0, 0, 0, -30], //name文字位置 对应 上右下左
        },
        splitLine: {
          // 网格线
          show: false,
          lineStyle: { //分割线
            color: "rgb(180, 180, 180)",
            width: 1,
            type: "dashed" //dotted:虚线 solid:实线
          }
        },
        axisLabel: {
          // 轴文字
          color: "rgb(30, 144, 255)",
          fontSize: 12,
        },
      },
 
    ],
    series: [{
        name: '电耗',
        type: 'bar',
        barWidth: '80%',
        data: [220, 152, 200, 334, 390, 330, 220],
        itemStyle: {
          color: 'rgb(180, 180, 180)'
        }
      },
 
    ]
  }
    // getMachineElectricTimer:null,
    // getTableDataTimer:null,
    // getMachineWaterTimer:null,
 
}