diff --git a/src/pages/goods-light-detail/index.vue b/src/pages/goods-light-detail/index.vue index f1b2527..77b0339 100644 --- a/src/pages/goods-light-detail/index.vue +++ b/src/pages/goods-light-detail/index.vue @@ -87,7 +87,7 @@
@@ -122,7 +122,6 @@ export default { value: '', spec_id: '', step: 0, - quantity: 1, dreamInfo: null, anyPrice: 0, // 随喜金额 swiperOption: { @@ -163,6 +162,10 @@ export default { lights.push(goods.slice(0 * i, 0 * i + 15)) } return lights; + }, + totalPrice(){ + if(!this.lightSize) return 0; + return this.lightSize.price * this.buy_quantity } }, mounted(){ @@ -202,10 +205,10 @@ export default { goods_id: this.currentLight.id, spec_id: this.lightSize.id, friendly_time: this.number, - quantity: this.quantity, + quantity: this.buy_quantity, title: this.data.details.title, subTitle: this.currentLight.name + ':'+this.lightSize.name, - amount: this.lightSize.price, + amount: this.totalPrice, from: 'goods_light', // 标识为通用商品 } }) @@ -227,7 +230,7 @@ export default { // 获取感恩功德 async getPayRecords(lType){ this.listType = lType.id; - const res = await getOrderCompare(this.query.temple_id, this.listType, this.query.goods_id, 3 ); + const res = await getOrderCompare(this.query.temple_id, this.listType, this.query.goods_id, 5 ); console.log('pay record', res) this.payList = res.list; }, diff --git a/src/pages/pay-result/index.vue b/src/pages/pay-result/index.vue index d69ee16..fbef8e8 100644 --- a/src/pages/pay-result/index.vue +++ b/src/pages/pay-result/index.vue @@ -39,6 +39,17 @@ export default { this.$router.replace({ name: 'merit-box', query: { temple_id: this.query.temple_id , open_box: 1}}) return } + // 佛前供灯再结善缘 + if(this.query.from === 'goods_light'){ + this.$router.replace({ + name: 'goods-light-detail', + query: { + goods_type: this.query.goods_type, + temple_id: this.query.temple_id, + } + }) + return + } const { goods_type, goods_id, temple_id, spec_ids } = this.query; this.onPushToGoodsDetail(goods_type, goods_id, temple_id, spec_ids) } diff --git a/wap/index.html b/wap/index.html index fd8a51e..056508c 100644 --- a/wap/index.html +++ b/wap/index.html @@ -1 +1 @@ -