From 67833a427ee0a6b27cb6eeee5ac76eee2d256091 Mon Sep 17 00:00:00 2001 From: wangsongsole Date: Mon, 17 Oct 2022 11:37:12 +0800 Subject: [PATCH] =?UTF-8?q?fix=EF=BC=9A=E4=BF=AE=E5=A4=8D=E5=95=86?= =?UTF-8?q?=E5=93=81=E8=AF=A6=E6=83=85=E4=BB=85=E7=99=BB=E5=BD=95=E5=A4=B1?= =?UTF-8?q?=E6=95=88=E8=B7=B3=E7=99=BB=E5=BD=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- coupon/details.html | 21 ++++++--------------- 1 file changed, 6 insertions(+), 15 deletions(-) diff --git a/coupon/details.html b/coupon/details.html index 24bb63e..84a3d36 100644 --- a/coupon/details.html +++ b/coupon/details.html @@ -221,7 +221,8 @@ popStatus: 1, /*1 成功 2提示 3失败 */ bottomText: '', /* 复制按钮 */ href: '',/* 支付地址 */ - receive_time: {} + receive_time: {}, + isLogin: false,/* 是否跳登录页 */ } }, @@ -333,8 +334,8 @@ }, /* 弹窗回调 */ - backFunctionPop (data) { - if (this.bottomText === '点击复制' && data) { + backFunctionPop (type) { + if (this.bottomText === '点击复制' && type) { var aux = document.createElement("input"); aux.setAttribute("value", this.href); document.body.appendChild(aux); @@ -344,13 +345,7 @@ this.openDialog('复制成功') } - if (data === 'couponCollection') { - setTimeout(() => { - window.location.replace('./couponCollection.html'); - }, 3000); - } - - if (data === 'entryLink') { + if (this.isLogin) { /*跳转起始页面*/ let entryLink = localStorage.getItem('entryLink'); setTimeout(() => { @@ -438,11 +433,7 @@ } else { this.openErrorDialog(res.message); if (res.code == 403) { - if (goodsCount > 1) { - this.backFunctionPop('couponCollection') - } else { - this.backFunctionPop('entryLink') - } + this.isLogin = true } } }).catch(err => {