Commit b4a0e5ed by 杨明

fixed

1 parent 454c684d
...@@ -220,7 +220,7 @@ export default { ...@@ -220,7 +220,7 @@ export default {
} }
}, },
computed: { computed: {
...mapState('marketing', ['packageList', 'subscribe', 'activityInfo']) ...mapState('marketing', ['packageList', 'subscribe', 'activityInfo', 'process'])
}, },
methods: { methods: {
...mapActions('marketing', ['setPackage', 'setProcess']), ...mapActions('marketing', ['setPackage', 'setProcess']),
...@@ -248,7 +248,8 @@ export default { ...@@ -248,7 +248,8 @@ export default {
// if (this.currentIndex == 1) this.carTableParams.checkSelectVal = carList // if (this.currentIndex == 1) this.carTableParams.checkSelectVal = carList
// if (this.currentIndex == 3) this.serviceTableParams.checkSelectVal = serviceList // if (this.currentIndex == 3) this.serviceTableParams.checkSelectVal = serviceList
}, },
getGiftList(val) { getGiftList(val, status) {
console.log(status, 'status')
const { merchantId } = this const { merchantId } = this
let params = { let params = {
merchantId, merchantId,
...@@ -256,6 +257,15 @@ export default { ...@@ -256,6 +257,15 @@ export default {
} }
this.$apis.giftBag.packageList(params).then(res => { this.$apis.giftBag.packageList(params).then(res => {
this.giftList = res || [] this.giftList = res || []
if (status === 'add') {
this.giftValue = this.giftList.find(item => item.name == '自定义套餐')?.id
this.setProcess({
1: {
...this.process[1],
giftId: this.giftValue
}
})
}
}) })
}, },
calcCarValue(scope) { calcCarValue(scope) {
...@@ -390,7 +400,7 @@ export default { ...@@ -390,7 +400,7 @@ export default {
this.$apis.giftBag.packageAdd(params).then(res => { this.$apis.giftBag.packageAdd(params).then(res => {
if (res) { if (res) {
this.giftVisible = false this.giftVisible = false
this.getGiftList(this.subscribe) this.getGiftList(this.subscribe, params.id ? '' : 'add')
} }
}) })
}, },
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!