Authored by htoooth

fix

... ... @@ -72,7 +72,8 @@ export default {
handleChange(index) {
const nav = this.navList[index];
if (this.activeKey === nav.label) {
// 第二次点击
if (this.activeKey === nav.label && index === 0) {
this.showFilter = !this.showFilter;
this.$emit('on-filter-change', this.showFilter);
return;
... ...
<template>
<div :class="prefixCls" v-show="show">
<div :class="prefixCls" v-if="show">
<slot></slot>
</div>
</template>
... ...
... ... @@ -53,7 +53,6 @@ export default {
methods: {
updateNav() {
this.navList = [];
console.log();
this.getTabs().forEach((pane, index) => {
this.navList.push({
label: pane.label,
... ...
... ... @@ -2,10 +2,10 @@
<LayoutApp>
<Tabs>
<template slot="panes">
<TabPane label="有货优惠券" disable="true">
<TabPane label="有货优惠券" :disable="true">
<YohoPage></YohoPage>
</TabPane>
<TabPane label="UFO优惠券" disable="false">
<TabPane label="UFO优惠券" :disable="true">
<UfoPage></UfoPage>
</TabPane>
</template>
... ... @@ -27,19 +27,7 @@ export default {
store.dispatch('coupon/yoho/fetchYohoList', {
type: TYPE.notuse,
refresh: true
}),
store.dispatch('coupon/yoho/fetchYohoList', {
type: TYPE.use,
refresh: true
}),
store.dispatch('coupon/yoho/fetchYohoList', {
type: TYPE.overtime,
refresh: true
}),
store.dispatch('coupon/yoho/fetchUfoList', {
limit: 100,
page: 1
}),
})
]);
},
components: {
... ...
... ... @@ -32,6 +32,7 @@ export default {
created() {
},
mounted() {
this.getList();
},
methods: {
getList() {
... ...
... ... @@ -114,6 +114,16 @@ export default {
},
mounted() {
this.fetchYohoNum();
this.$store.dispatch('coupon/yoho/fetchYohoList', {
type: TYPE.use,
refresh: true
});
this.$store.dispatch('coupon/yoho/fetchYohoList', {
type: TYPE.overtime,
refresh: true
});
},
methods: {
...mapActions(['getCouponCode', 'fetchYohoList', 'fetchYohoNum']),
... ...