<template>
  <div class="container normal-panel">
    <p class="normal-title normal-margin">管辖区域</p>
    <slot name="add"></slot>
    <tableLayout :layout="tablecols" :data="list" :custom="true" height="calc(100vh - 495px)">
      <template v-slot:customcol="scope">
        <p>{{scope.column.data[scope.column.columnname]}}</p>
      </template>
      <template v-slot:opreation="scope">
        <slot name="edit" :data="scope.data"></slot>
        <slot name="del" :data="scope.data"></slot>
      </template>
    </tableLayout>
  </div>
</template>

<script>
export default {
  props:['data'],
  data () {
    return {
      list:[]
    }
  },
  methods:{
    async query_areascope (sa_saleareaid) {
      const res = await this.$api.requested({
        "classname": "webmanage.sale.saleareascope.saleareascope",
        "method": "query_areascope",
        "content": {
          "sa_saleareaid":sa_saleareaid
        }
      })
      this.list = res.data
    }
  },
  mounted () {
  },
  created () {
    // 获取角色表结构
    this.tablecols = this.tool.tabelCol(this.$route.name)['saleScopeTable'].tablecols
  }
}

</script>
<style>
</style>