<template>
  <div>
    <charts
      style="margin-top: -40px"
      id="bizchart4"
      height="220px"
      width="460px"
      :option="option"
    />
  </div>
</template>

<script lang="js">
import charts from '../../../components/echarts/index.vue'
import * as echarts from "echarts";

export default {
  components: {charts},
  data() {
    return {
      option: {
        tooltip: {
          trigger: 'axis',
          axisPointer: {
            type: 'shadow'
          }
        },
        grid: {
          left: '3%',
          right: '4%',
          bottom: '2%',
          containLabel: true
        },
        xAxis: {
          axisTick: {
            show: false
          },
          type: 'category',
          data: ['1.', '2.', '3.', '4.', '5.', '6.'],
          axisLine: {
            lineStyle: {
              color: "#a4a2a2",
            }
          }
        },
        yAxis: {
          type: 'value',
          boundaryGap: [0, 0.01],
          axisLine: {
            lineStyle: {
              color: "#a4a2a2",
            }
          },
          splitLine: {
            show: true,
            lineStyle: {
              color:'rgba(128,126,126,0.25)'
            },
          },
        },
        label: {
          show: true,
          position: 'top',
          color:'rgba(245,126,31,0.74)',
        },
        series: [
          {
            name: '分享',
            type: 'bar',
            data: [23, 19, 18, 14, 11, 10],
            itemStyle: {
              normal: {
                color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                  offset: 0,
                  color: 'rgba(22,58,143)'
                }, {
                  offset: 1,
                  color: 'rgba(20,42,68)'
                }]),
              }
            },
          },
          {
            name: '群发',
            type: 'bar',
            data: [15, 13, 10, 10, 8, 7],
            itemStyle: {
              normal: {
                color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                  offset: 0,
                  color: 'rgba(135,85,34)'
                }, {
                  offset: 1,
                  color: 'rgba(67,42,55)'
                }]),
              }
            },
          }
        ]
      }
    }
  },
  created() {
    this.timingAcquisition()
  },
  methods: {
    timingAcquisition() {
      setInterval(() => {

      }, 10000)
    },

  }
}
</script>
