<template>
  <el-tabs v-model="tabIndex" type="border-card">
    <el-tab-pane label="产品属性" :name="0" v-if="checkPermi(['mall:setting:prod'])">
      <FieldProduct v-if="tabIndex == 0" />
    </el-tab-pane>
    <el-tab-pane label="分类设置" :name="1" v-if="checkPermi(['mall:setting:category'])">
      <CategorySet v-if="tabIndex == 1" />
    </el-tab-pane>
    <el-tab-pane label="品牌设置" :name="2" v-if="checkPermi(['mall:setting:brand'])">
      <BrandSet v-if="tabIndex == 2" />
    </el-tab-pane>
    <el-tab-pane label="供应商设置" :name="3" v-if="checkPermi(['mall:setting:supplier'])">
      <SupplierSet v-if="tabIndex == 3" />
    </el-tab-pane>
    <el-tab-pane label="常规设置" :name="4" v-if="checkPermi(['mall:setting:general'])">
      <GeneralSet v-if="tabIndex == 4" />
    </el-tab-pane>
    <!-- <el-tab-pane label="消息通知" :name="9" v-if="checkPermi(['mall:setting:msg'])">
      <MsgSend v-if="tabIndex == 9" />
    </el-tab-pane> -->
  </el-tabs>
</template>

<script setup>
import GeneralSet from './Comp/GeneralSet.vue'
import FieldProduct from './Comp/FieldProduct.vue'
// import MsgSend from './Comp/MsgSend.vue'
import CategorySet from './Comp/CategorySet.vue'
import BrandSet from './Comp/BrandSet.vue'
import SupplierSet from './Comp/SupplierSet.vue'
import { checkPermi } from '@/utils/permission'

const tabIndex = ref(0)
</script>

<style lang="scss" scoped></style>
