<template>
    <div>
        <el-tabs v-model="activeName" @tab-click="handleClick">
            <template v-for="item in tabsList">
                <el-tab-pane :name="item.code" :disabled="item.code > 1">
                    <span slot="label">{{item.name}}</span>
                    <graphy @dimension="dimension" :ref="'graphy' + item.code"></graphy>
                </el-tab-pane>
            </template>
        </el-tabs>
    </div>
</template>
<script>
import graphy from '@/components/graphy/business'
export default {
  components:{
    graphy
  },
  props: {
    tabsList: {
      type: Array
    }
  },
  data() {
    return {
      activeName: "1"
    };
  },
  created() {},
  mounted() {
    this.$refs['graphy' + 1][0].getData('Fl110108000327d8f006c39f49feb40e24a7ef223232181009102258bim.json')
  },
  methods: {
    handleClick(tab, event) {
    },
    dimension(list){
      this.$emit("dimension",list)
    }
  }
};
</script>
<style lang="less" scoped>
</style>
