From 463293002558273478333ed5334a6c43016ec8c1 Mon Sep 17 00:00:00 2001 From: wangsongsole Date: Tue, 1 Nov 2022 13:42:14 +0800 Subject: [PATCH] =?UTF-8?q?style=EF=BC=9A=E6=A0=B9=E6=8D=AE=E4=B8=8D?= =?UTF-8?q?=E5=90=8C=E6=B5=8F=E8=A7=88=E5=99=A8=E7=8E=AF=E5=A2=83=20?= =?UTF-8?q?=E5=88=A4=E6=96=AD=E5=AF=B9=E5=BA=94=E6=94=AF=E4=BB=98=E6=96=B9?= =?UTF-8?q?=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- coupon/details.html | 6 ++---- coupon/myOrder.html | 19 ++++++------------- 2 files changed, 8 insertions(+), 17 deletions(-) diff --git a/coupon/details.html b/coupon/details.html index d85862b..07fde40 100644 --- a/coupon/details.html +++ b/coupon/details.html @@ -542,7 +542,7 @@ let orderInfo = await this.createdOrder(payType); if (orderInfo.pay_status == 2 || [1, 2].includes(orderInfo.channel)) {//pay_status 2已支付 channel 1 支付宝 2微信 let orderNumber = orderInfo.pay_status == 2 ? orderInfo.order_number : orderInfo.original_order_number; - window.location.replace('/paysuccess.html?order_number=' + orderNumber+'&token='+localStorage.getItem('token')); + window.location.replace('/paysuccess.html?order_number=' + orderNumber + '&token=' + localStorage.getItem('token')); } else { this.createdPay(orderInfo.order_number); } @@ -554,7 +554,7 @@ let data = { "token": localStorage.getItem('token'), "key": localStorage.getItem('key'), - "code_batch_id": this.goodsDetail.coupon.code_batch_id||this.goodsDetail.code_batch_id, + "code_batch_id": this.goodsDetail.coupon.code_batch_id || this.goodsDetail.code_batch_id, "goods_id": this.goodInfo.goods_id, "account": this.account || '888888', /* 卡密时默认账号 */ "pay_type": payType == 2 ? 1 : 5, @@ -589,7 +589,6 @@ //根据环境去执行 payWayRun (result) { - console.log(391, this.payType); if (this.payType == 1) {// 1微信支付 2 支付宝支付 if (isWx()) { @@ -599,7 +598,6 @@ } if (this.payType == 2) {// 1微信支付 2 支付宝支付 if (isWx()) { - this.openErrorDialog(`请在其他浏览器打开链接`, '点击复制') this.href = result; } else { window.location.href = result; diff --git a/coupon/myOrder.html b/coupon/myOrder.html index a76d894..ea86c40 100644 --- a/coupon/myOrder.html +++ b/coupon/myOrder.html @@ -233,7 +233,7 @@ }, /* 去支付 */ - payFunction ({ payType, isSupport }) { + payFunction ({ payType }) { /* payType 1:微信 2:支付宝 */ /* 后端 微信是5 */ this.active = payType === 2 ? 1 : 5 @@ -250,16 +250,16 @@ if (code === 200) { this.getOrderList() - this.payRealFunction(isSupport) + this.payRealFunction() } }) } else { - this.payRealFunction(isSupport) + this.payRealFunction() } }, /* 调用支付 */ - payRealFunction (isSupport) { + payRealFunction () { req.axiosGet(`/key/coupon/createPay/${this.activeOrder.order_number}`, { token: localStorage.getItem('token') }).then(({ code, data, message }) => { if (code === 403) { this.popFunction({ title: '温馨提示', text: message, status: 2, b_text: '我知道了', show: true }) @@ -267,16 +267,9 @@ return this.redirect = true } - /* 支付宝跳转链接 */ + /* 跳转链接 */ if (code === 200) { - /* 判断浏览器 */ - if (isSupport) { - this.popFunction({ title: '温馨提示', text: `请在其他浏览器打开链接`, status: 2, b_text: '点击复制', show: true }) - this.href = data - return - } else { - window.location.href = data - } + window.location.href = data } }) },