<!--  -->
<template>
  <div class="m-container">
    <h2>
      <div class="squrt"></div>网管课管理
    </h2>
    <div class="m-core">
      <el-tabs v-model.trim="activeIndex"
               type="card"
               @tab-click="handleClick">
        <el-tab-pane label="网管课管理"
                     name="1">
          <accompanyList v-if="activeIndex ==='1'" />
        </el-tab-pane>
        <el-tab-pane label="网管课购买"
                     name="2">
          <accompanyBuys v-if="activeIndex ==='2'" />
        </el-tab-pane>
      </el-tabs>
    </div>
  </div>
</template>

<script>
import accompanyList from "@/views/accompanyManager/accompanyList";
import accompanyBuys from '@/views/accompanyManager/accompanyBuys'
export default {
  components: { accompanyList, accompanyBuys },
  data () {
    const { query } = this.$route
    return {
      activeIndex: query.opt || '1',
    };
  },
  //生命周期 - 创建完成（可以访问当前this实例）
  created () {

  },
  //生命周期 - 挂载完成（可以访问DOM元素）
  mounted () {

  },
  methods: {
    handleClick (evt) {
      this.changeHash(evt.name)
    }
  },
}
</script>
<style lang='scss' scoped>
</style>
