list.vue 851 Bytes
<template>
  <LayoutApp>
    <Tabs>
      <template slot="panes">
        <TabPane label="有货优惠券" :disable="true">
          <YohoPage></YohoPage>
        </TabPane>
        <TabPane label="UFO优惠券" :disable="true">
          <UfoPage></UfoPage>
        </TabPane>
      </template>
    </Tabs>
  </LayoutApp>
</template>

<script>

import Tabs from './components/tabs';
import YohoPage from './yoho';
import UfoPage from './ufo';
const TYPE = {notuse: 'notuse', use: 'use', overtime: 'overtime'};

export default {
  name: 'ListPage',
  asyncData({store}) {
    return Promise.all([
      store.dispatch('coupon/yoho/fetchYohoList', {
        type: TYPE.notuse,
        refresh: true
      })
    ]);
  },
  components: {
    Tabs,
    TabPane: Tabs.Pane,
    YohoPage,
    UfoPage
  }
};
</script>

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