|
@@ -116,11 +116,13 @@
|
|
|
|
|
|
confirmPrize() {
|
|
confirmPrize() {
|
|
let flag = false
|
|
let flag = false
|
|
- let data = {
|
|
|
|
- goodsId: this.payInfo.goodsId,
|
|
|
|
- skuId: this.payInfo.skuId,
|
|
|
|
- orderNum: this.orderNum,
|
|
|
|
- }
|
|
|
|
|
|
+ // let data = {
|
|
|
|
+ // goodsId: this.payInfo.goodsId,
|
|
|
|
+ // skuId: this.payInfo.skuId,
|
|
|
|
+ // num: this.orderNum,
|
|
|
|
+ // resource:'PAYMENT',
|
|
|
|
+ // }
|
|
|
|
+ // console.log(data);
|
|
if (flag) return
|
|
if (flag) return
|
|
if (this.payInfo.quantity == 0) {
|
|
if (this.payInfo.quantity == 0) {
|
|
uni.$u.toast('库存不足');
|
|
uni.$u.toast('库存不足');
|
|
@@ -134,17 +136,10 @@
|
|
title: '购买中'
|
|
title: '购买中'
|
|
});
|
|
});
|
|
flag = true
|
|
flag = true
|
|
- $http.post('/api/v1/mp/user/exchange/submit', data).then(res => {
|
|
|
|
- uni.hideLoading();
|
|
|
|
- flag = false
|
|
|
|
- if (res.code == 0) {
|
|
|
|
- this.$emit('success')
|
|
|
|
- } else if (res.code == 1021) {
|
|
|
|
- uni.$u.toast(res.msg);
|
|
|
|
- }
|
|
|
|
- }).catch(() => {
|
|
|
|
- flag = false
|
|
|
|
- uni.hideLoading();
|
|
|
|
|
|
+
|
|
|
|
+ uni.hideLoading();
|
|
|
|
+ uni.navigateTo({
|
|
|
|
+ url: `/packageGoods/order/settlement?goodsId=${ this.payInfo.goodsId }&skuId=${ this.payInfo.skuId?this.payInfo.skuId:0 }&num=${ this.orderNum }`
|
|
})
|
|
})
|
|
},
|
|
},
|
|
|
|
|