<template>
  <el-tabs v-model="tabName">
    <el-tab-pane label="成交列表" name="list">
      <template v-if="tabName == 'list'">
        <OrderList v-if="appStore.getAppInfo?.instanceType == 1" />
        <MallOrderList v-else-if="appStore.getAppInfo?.instanceType == 2" />
      </template>
    </el-tab-pane>
    <el-tab-pane label="回款申请" name="commission">
      <Reback v-if="tabName == 'commission'" />
    </el-tab-pane>
    <el-tab-pane label="售后申请" name="aftersale">
      <AfterSales v-if="tabName == 'aftersale'" />
    </el-tab-pane>
    <el-tab-pane label="发货列表" name="delivery" v-if="appStore.getAppInfo?.instanceType == 2">
      <Delivery v-if="tabName == 'delivery'" />
    </el-tab-pane>
  </el-tabs>
</template>

<script setup name="ClueOrder">
import { useAppStore } from '@/store/modules/app'
import OrderList from './Comp/OrderList.vue'
import MallOrderList from './Comp/MallOrderList.vue'
import Reback from './Comp/Reback.vue'
import AfterSales from './Comp/AfterSales.vue'
import Delivery from './Comp/Delivery.vue'

const appStore = useAppStore()
const tabName = ref('list')
</script>

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