whyczyk
2021-03-04 c84d328cb6448786aee00f1b0684aaa07186e410
src/components/charts/abeamProChart.vue
@@ -8,8 +8,10 @@
<script>
  import * as echarts from 'echarts';
  //引入提示框
  import "echarts/lib/component/tooltip";
  //引入chart字体自适应
  import {
    chartFontsize
  } from '@/assets/js/chartFontsize'
  export default {
    name: "abeamProChart",
    chart: "",
@@ -31,6 +33,7 @@
        this.$options.chart.setOption(opt);
      },
      setData(sendData) {
        this.$options.chartData = sendData;
        let dataColor = sendData.color;
        let bgColor = sendData.bgColor;
        let yData = sendData.yData;
@@ -69,7 +72,8 @@
            axisLabel: {
              show: true,
              textStyle: {
                color: '#fff'
                color: '#fff',
                fontSize: chartFontsize(12),
              },
            },
            splitLine: {
@@ -88,7 +92,8 @@
            axisLabel: {
              show: true,
              textStyle: {
                color: '#fff'
                color: '#fff',
                fontSize: chartFontsize(12),
              },
            },
            splitLine: {
@@ -130,7 +135,7 @@
                normal: {
                  show: true,
                  position: 'insideRight',
                  fontSize: 20,
                  fontSize: chartFontsize(20),
                  color: '#021750'
                }
              },
@@ -167,6 +172,7 @@
      },
      resize() {
        this.$options.chart.resize();
        this.setData(this.$options.chartData);
      }
    },
    mounted() {