🦀️ fix: 修复bug
This commit is contained in:
parent
97e776f5c5
commit
cb0c4114bd
|
@ -355,7 +355,7 @@
|
|||
if (res.goods.channel == 2) {
|
||||
if (res.goods.is_webview == 1) {
|
||||
/* 公众号 */
|
||||
this.publicCollection(res.code_batch_id);
|
||||
this.publicCollection(res.order_number);
|
||||
} else if (ua.indexOf("dingtalk") > -1) {
|
||||
//在钉钉内置环境打开,不能唤起微信小程序
|
||||
window.location.href = res.wechat_redirect_url;
|
||||
|
@ -367,24 +367,22 @@
|
|||
},
|
||||
|
||||
/* 公众号领取 */
|
||||
publicCollection (code_batch_id) {
|
||||
publicCollection (order_number) {
|
||||
let params = {
|
||||
token: localStorage.getItem('token'),
|
||||
code_batch_id: code_batch_id,
|
||||
order_number,
|
||||
channel: 2,
|
||||
channel_user_id: this.openId,
|
||||
is_webview: 1
|
||||
};
|
||||
req.axiosPost("/voucher/groupVoucherGrant", params)
|
||||
req.axiosPost("/voucher/grant", params)
|
||||
.then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.message = '领取成功';
|
||||
this.getProductDetail();
|
||||
this.popFunction({ title: '温馨提示', text: '领取成功', status: 1, b_text: '我知道了', show: true });
|
||||
this.getOrderList();
|
||||
} else {
|
||||
this.axiosErrorFun(res.code, res.message);
|
||||
this.popFunction({ title: '温馨提示', text: res.message, status: 3, b_text: '我知道了', show: true });
|
||||
}
|
||||
})
|
||||
.catch((err) => { this.loading = false; });
|
||||
;
|
||||
});
|
||||
},
|
||||
|
||||
// 单条弹框
|
||||
|
|
|
@ -212,16 +212,21 @@
|
|||
/* 公众号领取 */
|
||||
publicCollection () {
|
||||
let params = {
|
||||
token: localStorage.getItem('token'),
|
||||
code_batch_id: this.code_batch_id,
|
||||
order_number: this.orderId,
|
||||
channel: 2,
|
||||
channel_user_id: this.openId,
|
||||
is_webview: 1
|
||||
};
|
||||
req.axiosPost("/voucher/groupVoucherGrant", params)
|
||||
|
||||
req.axiosPost("/voucher/grant", params)
|
||||
.then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.message = '领取成功';
|
||||
this.getProductDetail();
|
||||
this.openTipDialog({
|
||||
show: true,
|
||||
title: '温馨提示',
|
||||
status: 1,/*1 成功 2提示 3失败 */
|
||||
text: '领取成功'
|
||||
});
|
||||
} else {
|
||||
this.openTipDialog({
|
||||
show: true,
|
||||
|
|
Loading…
Reference in New Issue