<template>
  <div class="app-container">
    <el-tabs v-model="activeName">
      <el-tab-pane v-for="item in tables" :key="item.name" :label="item.title" :name="item.component" />
      <component :is="activeName" />
    </el-tabs>
  </div>
</template>
<script>
import Administrator from './administrator'
import AdministratorAuthResource from './administrator-auth-resource'
export default {
  name: 'FamilyConfig',
  components: { Administrator, AdministratorAuthResource },
  data() {
    return {
      activeName: 'Administrator'
    }
  },
  computed: {
    tables() {
      return [
        {
          title: this.$t('pages.appManager.tabs.administratorList'),
          component: 'Administrator'
        },
        {
          title: this.$t('pages.appManager.tabs.permissionManagement'),
          component: 'AdministratorAuthResource'
        }
      ]
    }
  }
}
</script>
