From c6dd5eac670dede2578f73ba27653a7386d3b6e4 Mon Sep 17 00:00:00 2001 From: Chopper Date: Wed, 16 Jun 2021 16:44:30 +0800 Subject: [PATCH] =?UTF-8?q?=E8=BF=98=E5=8E=9F=E7=99=BB=E5=BD=95=E9=97=AE?= =?UTF-8?q?=E9=A2=98=EF=BC=8Ch5=E6=94=AF=E4=BB=98=E5=AE=9D=E6=94=AF?= =?UTF-8?q?=E4=BB=98=E6=97=A0=E6=B3=95=E6=94=AF=E4=BB=98=E5=8E=9F=E5=9B=A0?= =?UTF-8?q?=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/cart/payment/payOrder.vue | 21 +++++++++++---------- pages/passport/onClickLogin.vue | 33 +++++++++------------------------ 2 files changed, 20 insertions(+), 34 deletions(-) diff --git a/pages/cart/payment/payOrder.vue b/pages/cart/payment/payOrder.vue index cb7de31..cbfa209 100644 --- a/pages/cart/payment/payOrder.vue +++ b/pages/cart/payment/payOrder.vue @@ -148,7 +148,7 @@ awaitPay(payment){ - this.$u.debounce(this.pay(payment), 3000) + this.pay(payment) }, @@ -225,16 +225,17 @@ await API_Trade.initiatePay(paymentMethod, paymentClient, params).then( (res) => { let response = res.data; - //如果支付异常 - if (!response.success) { - - uni.showModal({ - content: response.message, - showCancel: false, - }) - return; + //如果非支付宝支付才需要进行判定,因为支付宝h5支付是直接输出的,没有返回所谓的消息状态 + if(paymentMethod !== "ALIPAY"){ + //如果支付异常 + if (!response.success) { + uni.showModal({ + content: response.message, + showCancel: false, + }) + return; + } } - if (paymentMethod === "ALIPAY") { document.write(response); } else if (paymentMethod === "WECHAT") { diff --git a/pages/passport/onClickLogin.vue b/pages/passport/onClickLogin.vue index 4fe1766..cfadf7e 100644 --- a/pages/passport/onClickLogin.vue +++ b/pages/passport/onClickLogin.vue @@ -1,9 +1,6 @@ - +