heyujie
2021-11-03 57094ef66e4afb413c39ecd181e65938315c195c
src/pages/shuohuangMonitorAnalyze/components/charts/bar.vue
@@ -1,32 +1,29 @@
<template>
  <div ref="barChart" style="width: 100%; height: 100%;"></div>
  <div ref="barChart" style="width: 100%; height: 100%" class="Bar"></div>
</template>
<script>
export default {
  data () {
    return {
    }
  data() {
    return {};
  },
  props: {
    options:{
    options: {
      type: Object,
    }
    },
  },
  mounted(){
  mounted() {
    this.initBar();
  },
  methods: {
    initBar(){
      this.$nextTick(()=>{
        let dom = this.$echarts.init(this.$refs['barChart']);
    initBar() {
      this.$nextTick(() => {
        let dom = this.$echarts.init(this.$refs["barChart"]);
        dom.setOption(this.options);
      })
    }
  }
}
      });
    },
  },
};
</script>
<style >