|
@@ -632,12 +632,16 @@
|
|
|
saleyg: {
|
|
|
list: [],
|
|
|
},
|
|
|
- sale_yg: {}
|
|
|
+ sale_yg: {},
|
|
|
+ spid:'',
|
|
|
};
|
|
|
},
|
|
|
computed: mapGetters(['isLogin']),
|
|
|
onLoad: function(options) {
|
|
|
- this.ptype = options.product_type
|
|
|
+ this.ptype = options.product_type;
|
|
|
+ if(options.spid){
|
|
|
+ this.spid = options.spid;
|
|
|
+ }
|
|
|
if (this.ptype == 6) {
|
|
|
this.getList()
|
|
|
}
|
|
@@ -704,6 +708,9 @@
|
|
|
this.getCodeData();
|
|
|
}
|
|
|
// #endif
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
},
|
|
|
/**
|
|
|
* 生命周期函数--监听页面显示
|
|
@@ -1101,23 +1108,24 @@
|
|
|
this.computedPrice()
|
|
|
},
|
|
|
computedPrice: function() {
|
|
|
- let shippingType = this.shippingType;
|
|
|
- postOrderComputed(this.orderKey, {
|
|
|
- addressId: this.addressId,
|
|
|
- useIntegral: this.useIntegral ? 1 : 0,
|
|
|
- couponId: this.priceGroup.couponPrice == 0 ? 0 : this.couponId,
|
|
|
- shipping_type: this.tableId ? 4 : parseInt(shippingType) + 1,
|
|
|
- payType: this.payType
|
|
|
+ const that = this;
|
|
|
+ let shippingType = that.shippingType;
|
|
|
+ postOrderComputed(that.orderKey, {
|
|
|
+ addressId: that.addressId,
|
|
|
+ useIntegral: that.useIntegral ? 1 : 0,
|
|
|
+ couponId: that.priceGroup.couponPrice == 0 ? 0 : that.couponId,
|
|
|
+ shipping_type: that.tableId ? 4 : parseInt(shippingType) + 1,
|
|
|
+ payType: that.payType
|
|
|
}).then(res => {
|
|
|
let result = res.data.result;
|
|
|
if (result) {
|
|
|
- this.totalPrice = result.pay_price;
|
|
|
- this.integral_price = result.deduction_price;
|
|
|
- this.coupon_price = result.coupon_price;
|
|
|
- this.promotions_detail = result.promotions_detail;
|
|
|
- this.integral = this.useIntegral ? result.SurplusIntegral : this.userInfo.integral;
|
|
|
- this.$set(this.priceGroup, 'storePostage', shippingType == 1 ? 0 : result.pay_postage);
|
|
|
- this.$set(this.priceGroup, 'storePostageDiscount', result.storePostageDiscount);
|
|
|
+ that.totalPrice = result.pay_price;
|
|
|
+ that.integral_price = result.deduction_price;
|
|
|
+ that.coupon_price = result.coupon_price;
|
|
|
+ that.promotions_detail = result.promotions_detail;
|
|
|
+ that.integral = that.useIntegral ? result.SurplusIntegral : that.userInfo.integral;
|
|
|
+ that.$set(that.priceGroup, 'storePostage', shippingType == 1 ? 0 : result.pay_postage);
|
|
|
+ that.$set(that.priceGroup, 'storePostageDiscount', result.storePostageDiscount);
|
|
|
}
|
|
|
}).catch(err => {
|
|
|
return that.$util.Tips({
|
|
@@ -1898,6 +1906,7 @@
|
|
|
title: '请选择支付方式'
|
|
|
});
|
|
|
data = {
|
|
|
+ sale:that.spid,
|
|
|
sale_uid: that.sale_yg.id || 0,
|
|
|
collate_code_id: that.collage_id || that.tableId,
|
|
|
custom_form: that.confirm,
|