Compare commits
No commits in common. "15cb892cb681b6510873731bf465532b041c0dfc" and "6b19df867c757e74a4909ef6ccd3e7e7c90c6cb0" have entirely different histories.
15cb892cb6
...
6b19df867c
|
@ -607,6 +607,7 @@
|
|||
|
||||
payJZ() {
|
||||
let that = this;
|
||||
if (that.openWay == 1) { //零钱支付
|
||||
uni.showModal({
|
||||
title: '付款提示',
|
||||
content: '确认支付' + that.tpayMoney + '元吗?',
|
||||
|
@ -614,18 +615,16 @@
|
|||
if (re.confirm) {
|
||||
that.$queue.showLoading('支付中...')
|
||||
// console.log('用户点击确定');
|
||||
if (that.openWay == 1) { //零钱支付
|
||||
that.$Request.post("/app/artificer/payOrders", {
|
||||
ordersId: that.ordersId,
|
||||
}).then(ret => {
|
||||
uni.hideLoading();
|
||||
if (ret.code == 0) {
|
||||
uni.showToast({
|
||||
title: '支付成功'
|
||||
})
|
||||
uni.switchTab({
|
||||
url: '/pages/my/index'
|
||||
title: '支付成功',
|
||||
icon: 'none'
|
||||
})
|
||||
// that.getOrder()
|
||||
|
||||
} else {
|
||||
uni.showToast({
|
||||
|
@ -634,6 +633,11 @@
|
|||
})
|
||||
}
|
||||
});
|
||||
} else if (re.cancel) {
|
||||
// that.getOrder()
|
||||
}
|
||||
}
|
||||
})
|
||||
} else if (that.openWay == 2) { //微信支付
|
||||
// #ifdef MP-WEIXIN
|
||||
let data = {
|
||||
|
@ -652,11 +656,10 @@
|
|||
signType: ret.data.signType,
|
||||
paySign: ret.data.sign,
|
||||
success: function(ret) {
|
||||
console.log(ret)
|
||||
uni.showToast({
|
||||
title: '支付成功'
|
||||
})
|
||||
uni.switchTab({
|
||||
url: '/pages/my/index'
|
||||
title: '支付成功',
|
||||
icon: 'none'
|
||||
})
|
||||
// that.getOrder()
|
||||
// this.$queue.showToast('支付成功');
|
||||
|
@ -688,12 +691,6 @@
|
|||
that.$Request.post('/app/wxPay/payOrder', data).then(rea => {
|
||||
that.showpay = false
|
||||
if (rea.code == 0) {
|
||||
uni.showToast({
|
||||
title: '支付成功'
|
||||
})
|
||||
uni.switchTab({
|
||||
url: '/pages/my/index'
|
||||
})
|
||||
that.callPay(rea.data);
|
||||
} else {
|
||||
uni.showToast({
|
||||
|
@ -710,12 +707,6 @@
|
|||
that.$Request.post('/app/wxPay/payOrder', data).then(rea => {
|
||||
that.showpay = false
|
||||
if (rea.code == 0) {
|
||||
uni.showToast({
|
||||
title: '支付成功'
|
||||
})
|
||||
uni.switchTab({
|
||||
url: '/pages/my/index'
|
||||
})
|
||||
const urlArr = window.location.href;
|
||||
const hostUrl = urlArr.split("/");
|
||||
const callBack = hostUrl[0] + "//" + hostUrl[2] + "/";
|
||||
|
@ -753,12 +744,6 @@
|
|||
}
|
||||
that.$Request.post('/app/aliPay/payOrder', data).then(
|
||||
rea => {
|
||||
uni.showToast({
|
||||
title: '支付成功'
|
||||
})
|
||||
uni.switchTab({
|
||||
url: '/pages/my/index'
|
||||
})
|
||||
that.showpay = false
|
||||
const div = document.createElement('div')
|
||||
div.innerHTML = rea.data //此处form就是后台返回接收到的数据
|
||||
|
@ -774,24 +759,12 @@
|
|||
}
|
||||
that.$Request.post('/app/aliPay/payOrder', data).then(
|
||||
rea => {
|
||||
uni.showToast({
|
||||
title: '支付成功'
|
||||
})
|
||||
uni.switchTab({
|
||||
url: '/pages/my/index'
|
||||
})
|
||||
that.showpay = false
|
||||
that.setPayment('alipay', rea.data);
|
||||
});
|
||||
// #endif
|
||||
}
|
||||
|
||||
} else if (re.cancel) {
|
||||
// that.getOrder()
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
},
|
||||
saveJZ(classifyId) {
|
||||
let data = {
|
||||
|
@ -955,6 +928,7 @@
|
|||
this.payJZ();
|
||||
return;
|
||||
}
|
||||
if (that.openWay == 1) { //零钱支付
|
||||
uni.showModal({
|
||||
title: '付款提示',
|
||||
content: '确认支付' + that.tpayMoney + '元吗?',
|
||||
|
@ -962,7 +936,6 @@
|
|||
if (re.confirm) {
|
||||
that.$queue.showLoading('支付中...')
|
||||
console.log('用户点击确定');
|
||||
if (that.openWay == 1) { //零钱支付
|
||||
that.$Request.post("/app/artificer/payOrders", {
|
||||
ordersId: that.ordersId,
|
||||
}).then(res => {
|
||||
|
@ -971,10 +944,7 @@
|
|||
uni.showToast({
|
||||
title: '支付成功'
|
||||
})
|
||||
uni.switchTab({
|
||||
url: '/pages/my/index'
|
||||
})
|
||||
that.getOrder()
|
||||
// that.getOrder()
|
||||
} else {
|
||||
uni.showToast({
|
||||
title: res.msg,
|
||||
|
@ -982,6 +952,13 @@
|
|||
})
|
||||
}
|
||||
});
|
||||
} else if (re.cancel) {
|
||||
uni.hideLoading();
|
||||
console.log('用户点击取消');
|
||||
}
|
||||
}
|
||||
|
||||
})
|
||||
} else if (that.openWay == 2) { //微信支付
|
||||
that.$queue.showLoading('支付中...')
|
||||
// #ifdef MP-WEIXIN
|
||||
|
@ -1001,17 +978,17 @@
|
|||
signType: ret.data.signType,
|
||||
paySign: ret.data.sign,
|
||||
success: function(ret) {
|
||||
console.log(ret)
|
||||
uni.showToast({
|
||||
title: '支付成功'
|
||||
title: '支付成功',
|
||||
icon: 'none'
|
||||
})
|
||||
uni.switchTab({
|
||||
url: '/pages/my/index'
|
||||
})
|
||||
that.getOrder()
|
||||
// that.getOrder()
|
||||
// this.$queue.showToast('支付成功');
|
||||
|
||||
|
||||
// uni.switchTab({
|
||||
// url: '/pages/my/index'
|
||||
// })
|
||||
},
|
||||
fail: function(err) {
|
||||
// this.$queue.showToast('支付失败');
|
||||
|
@ -1036,12 +1013,6 @@
|
|||
that.$Request.post('/app/wxPay/payOrder', data).then(rea => {
|
||||
that.showpay = false
|
||||
if (rea.code == 0) {
|
||||
uni.showToast({
|
||||
title: '支付成功'
|
||||
})
|
||||
uni.switchTab({
|
||||
url: '/pages/my/index'
|
||||
})
|
||||
that.callPay(rea.data);
|
||||
} else {
|
||||
uni.showToast({
|
||||
|
@ -1064,12 +1035,6 @@
|
|||
// window.location = rea.mweb_url + url
|
||||
that.showpay = false
|
||||
if (rea.code == 0) {
|
||||
uni.showToast({
|
||||
title: '支付成功'
|
||||
})
|
||||
uni.switchTab({
|
||||
url: '/pages/my/index'
|
||||
})
|
||||
const urlArr = window.location.href;
|
||||
const hostUrl = urlArr.split("/");
|
||||
const callBack = hostUrl[0] + "//" + hostUrl[2] + "/";
|
||||
|
@ -1108,12 +1073,6 @@
|
|||
}
|
||||
that.$Request.post('/app/aliPay/payOrder', data).then(
|
||||
rea => {
|
||||
uni.showToast({
|
||||
title: '支付成功'
|
||||
})
|
||||
uni.switchTab({
|
||||
url: '/pages/my/index'
|
||||
})
|
||||
const div = document.createElement('div')
|
||||
div.innerHTML = rea.data //此处form就是后台返回接收到的数据
|
||||
document.body.appendChild(div)
|
||||
|
@ -1128,25 +1087,10 @@
|
|||
}
|
||||
that.$Request.post('/app/aliPay/payOrder', data).then(
|
||||
rea => {
|
||||
uni.showToast({
|
||||
title: '支付成功'
|
||||
})
|
||||
uni.switchTab({
|
||||
url: '/pages/my/index'
|
||||
})
|
||||
that.setPayment('alipay', rea.data);
|
||||
});
|
||||
// #endif
|
||||
}
|
||||
|
||||
} else if (re.cancel) {
|
||||
uni.hideLoading();
|
||||
console.log('用户点击取消');
|
||||
}
|
||||
}
|
||||
|
||||
})
|
||||
|
||||
},
|
||||
callPay: function(response) {
|
||||
if (typeof WeixinJSBridge === "undefined") {
|
||||
|
|
|
@ -957,10 +957,11 @@
|
|||
pay() {
|
||||
let that = this
|
||||
this.showpay = false
|
||||
// if (this.paySel != 0) {
|
||||
// this.payJZ();
|
||||
// return;
|
||||
// }
|
||||
if (this.paySel != 0) {
|
||||
this.payJZ();
|
||||
return;
|
||||
}
|
||||
if (that.openWay == 1) { //零钱支付
|
||||
uni.showModal({
|
||||
title: '付款提示',
|
||||
content: '确认支付' + that.tpayMoney + '元吗?',
|
||||
|
@ -968,7 +969,6 @@
|
|||
if (re.confirm) {
|
||||
that.$queue.showLoading('支付中...')
|
||||
console.log('用户点击确定');
|
||||
if (that.openWay == 1) { //零钱支付
|
||||
that.$Request.post("/app/artificer/payOrders", {
|
||||
ordersId: that.ordersId,
|
||||
}).then(res => {
|
||||
|
@ -977,9 +977,6 @@
|
|||
uni.showToast({
|
||||
title: '支付成功'
|
||||
})
|
||||
uni.switchTab({
|
||||
url: '/pages/my/index'
|
||||
})
|
||||
// that.getOrder()
|
||||
} else {
|
||||
uni.showToast({
|
||||
|
@ -988,6 +985,13 @@
|
|||
})
|
||||
}
|
||||
});
|
||||
} else if (re.cancel) {
|
||||
uni.hideLoading();
|
||||
console.log('用户点击取消');
|
||||
}
|
||||
}
|
||||
|
||||
})
|
||||
} else if (that.openWay == 2) { //微信支付
|
||||
that.$queue.showLoading('支付中...')
|
||||
// #ifdef MP-WEIXIN
|
||||
|
@ -1007,11 +1011,10 @@
|
|||
signType: ret.data.signType,
|
||||
paySign: ret.data.sign,
|
||||
success: function(ret) {
|
||||
console.log(ret)
|
||||
uni.showToast({
|
||||
title: '支付成功'
|
||||
})
|
||||
uni.switchTab({
|
||||
url: '/pages/my/index'
|
||||
title: '支付成功',
|
||||
icon: 'none'
|
||||
})
|
||||
// that.getOrder()
|
||||
// this.$queue.showToast('支付成功');
|
||||
|
@ -1043,12 +1046,6 @@
|
|||
that.$Request.post('/app/wxPay/payOrder', data).then(rea => {
|
||||
that.showpay = false
|
||||
if (rea.code == 0) {
|
||||
uni.showToast({
|
||||
title: '支付成功'
|
||||
})
|
||||
uni.switchTab({
|
||||
url: '/pages/my/index'
|
||||
})
|
||||
that.callPay(rea.data);
|
||||
} else {
|
||||
uni.showToast({
|
||||
|
@ -1071,12 +1068,6 @@
|
|||
// window.location = rea.mweb_url + url
|
||||
that.showpay = false
|
||||
if (rea.code == 0) {
|
||||
uni.showToast({
|
||||
title: '支付成功'
|
||||
})
|
||||
uni.switchTab({
|
||||
url: '/pages/my/index'
|
||||
})
|
||||
const urlArr = window.location.href;
|
||||
const hostUrl = urlArr.split("/");
|
||||
const callBack = hostUrl[0] + "//" + hostUrl[2] + "/";
|
||||
|
@ -1102,12 +1093,6 @@
|
|||
console.log(rea)
|
||||
that.showpay = false
|
||||
if (rea.code == 0) {
|
||||
uni.showToast({
|
||||
title: '支付成功'
|
||||
})
|
||||
uni.switchTab({
|
||||
url: '/pages/my/index'
|
||||
})
|
||||
that.isCheckPay(rea.code, 'wxpay', JSON.stringify(rea.data));
|
||||
}
|
||||
});
|
||||
|
@ -1121,12 +1106,6 @@
|
|||
}
|
||||
that.$Request.post('/app/aliPay/payOrder', data).then(
|
||||
rea => {
|
||||
uni.showToast({
|
||||
title: '支付成功'
|
||||
})
|
||||
uni.switchTab({
|
||||
url: '/pages/my/index'
|
||||
})
|
||||
const div = document.createElement('div')
|
||||
div.innerHTML = rea.data //此处form就是后台返回接收到的数据
|
||||
document.body.appendChild(div)
|
||||
|
@ -1141,25 +1120,10 @@
|
|||
}
|
||||
that.$Request.post('/app/aliPay/payOrder', data).then(
|
||||
rea => {
|
||||
uni.showToast({
|
||||
title: '支付成功'
|
||||
})
|
||||
uni.switchTab({
|
||||
url: '/pages/my/index'
|
||||
})
|
||||
that.setPayment('alipay', rea.data);
|
||||
});
|
||||
// #endif
|
||||
}
|
||||
|
||||
} else if (re.cancel) {
|
||||
uni.hideLoading();
|
||||
console.log('用户点击取消');
|
||||
}
|
||||
}
|
||||
|
||||
})
|
||||
|
||||
},
|
||||
callPay: function(response) {
|
||||
if (typeof WeixinJSBridge === "undefined") {
|
||||
|
|
Loading…
Reference in New Issue