<template>
  <div class="app-container home">
    <template v-if="merchantId">
      <Dashboard v-if="shopState === '002'" />
      <MerchantForm v-else :merchantId="merchantId"/>
    </template>
    <template v-else>
      <Operation/>
    </template>
  </div>
</template>

<script>
import Dashboard from '@/views/dashboard'
import Operation from '@/views/dashboard/operation'
import MerchantForm from '@/views/merchant/info/components/MerchantForm'
import { mapGetters } from 'vuex'

export default {
  name: "Index",
  components: {Dashboard, MerchantForm, Operation},
  computed: {
    ...mapGetters(['merchantId', 'shopState']),
  }
}
</script>