From 80279f902a84727874f2e32e5fc5e196bef5c4d3 Mon Sep 17 00:00:00 2001 From: zhangds Date: Wed, 28 Feb 2024 14:13:05 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E5=85=91=E6=8D=A2?= =?UTF-8?q?=E7=A0=81=E7=99=BB=E5=BD=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- index.html | 5 +++-- packkey/libs.js | 2 +- packkey/ysf-reduce.html | 4 ++-- packkey/ysf.html | 4 ++-- packkey/zfb-redPackets.html | 4 ++-- packkey/zfb-reduce.html | 4 ++-- 6 files changed, 12 insertions(+), 11 deletions(-) diff --git a/index.html b/index.html index c606d3a..841187b 100644 --- a/index.html +++ b/index.html @@ -224,12 +224,13 @@ methods: { // 判断是否是包码 跳转对应的包码页面 **** goToPackKey(data, type) { + // 存储数据 + sessionStorage.setItem("bm_auth", JSON.stringify(data)); + // 包码打开结算 if (!data.settlement_data.is_settlement && data.settlement_data.settlement_type === 2) { settlementFun(data.token, data.settlement_data.settlement_type); } - // 存储数据 - sessionStorage.setItem("bm_auth", JSON.stringify(data)); setTimeout(() => { if (type) { diff --git a/packkey/libs.js b/packkey/libs.js index aa628a7..70de0c4 100644 --- a/packkey/libs.js +++ b/packkey/libs.js @@ -5,7 +5,7 @@ */ const settlementFun = (token, settlementType) => { let obj_yz_data = JSON.parse(sessionStorage.getItem("bm_auth")); - if (obj_yz_data.settlement_data.is_settlement) { + if (obj_yz_data && obj_yz_data.settlement_data.is_settlement) { return; } let params = { diff --git a/packkey/ysf-reduce.html b/packkey/ysf-reduce.html index 7525624..1b5dfcd 100644 --- a/packkey/ysf-reduce.html +++ b/packkey/ysf-reduce.html @@ -187,7 +187,7 @@ .then(({ code, data, message }) => { // 使用结算 6 // 卡密做特殊处理,复制才会触发 - if (bm_obj_data && !bm_obj_data.settlement_data.is_settlement && bm_obj_data.settlement_data.settlement_type === 6 && self.ysf.product_type !== 2) { + if (bm_obj_data && !bm_obj_data.settlement_data.is_settlement && bm_obj_data.settlement_data.settlement_type === 6) { settlementFun(bm_obj_data.token, bm_obj_data.settlement_data.settlement_type); } @@ -196,7 +196,7 @@ if (code == 200) { // 使用成功结算 7 // 直充类 上游充值返回成功 - if (bm_obj_data && !bm_obj_data.settlement_data.is_settlement && bm_obj_data.settlement_data.settlement_type === 7 && self.ysf.product_type !== 2) { + if (bm_obj_data && !bm_obj_data.settlement_data.is_settlement && bm_obj_data.settlement_data.settlement_type === 7) { settlementFun(bm_obj_data.token, bm_obj_data.settlement_data.settlement_type); } this.verificationYsf(data); diff --git a/packkey/ysf.html b/packkey/ysf.html index 58e2bcc..b9b5dfa 100644 --- a/packkey/ysf.html +++ b/packkey/ysf.html @@ -170,7 +170,7 @@ .then(({ code, data, message }) => { // 使用结算 6 // 卡密做特殊处理,复制才会触发 - if (bm_obj_data && !bm_obj_data.settlement_data.is_settlement && bm_obj_data.settlement_data.settlement_type === 6 && self.ysf.product_type !== 2) { + if (bm_obj_data && !bm_obj_data.settlement_data.is_settlement && bm_obj_data.settlement_data.settlement_type === 6) { settlementFun(bm_obj_data.token, bm_obj_data.settlement_data.settlement_type); } @@ -178,7 +178,7 @@ if (code == 200) { // 使用成功结算 7 // 直充类 上游充值返回成功 - if (bm_obj_data && !bm_obj_data.settlement_data.is_settlement && bm_obj_data.settlement_data.settlement_type === 7 && self.ysf.product_type !== 2) { + if (bm_obj_data && !bm_obj_data.settlement_data.is_settlement && bm_obj_data.settlement_data.settlement_type === 7) { settlementFun(bm_obj_data.token, bm_obj_data.settlement_data.settlement_type); } diff --git a/packkey/zfb-redPackets.html b/packkey/zfb-redPackets.html index f8aaeb2..8a1c6d8 100644 --- a/packkey/zfb-redPackets.html +++ b/packkey/zfb-redPackets.html @@ -180,7 +180,7 @@ .then(({ code, data, message }) => { // 使用结算 6 // 卡密做特殊处理,复制才会触发 - if (bm_obj_data && !bm_obj_data.settlement_data.is_settlement && bm_obj_data.settlement_data.settlement_type === 6 && self.goodInfo.product_type !== 2) { + if (bm_obj_data && !bm_obj_data.settlement_data.is_settlement && bm_obj_data.settlement_data.settlement_type === 6) { settlementFun(bm_obj_data.token, bm_obj_data.settlement_data.settlement_type); } @@ -188,7 +188,7 @@ if (code == 200) { // 使用成功结算 7 // 直充类 上游充值返回成功 - if (bm_obj_data && !bm_obj_data.settlement_data.is_settlement && bm_obj_data.settlement_data.settlement_type === 7 && self.goodInfo.product_type !== 2) { + if (bm_obj_data && !bm_obj_data.settlement_data.is_settlement && bm_obj_data.settlement_data.settlement_type === 7) { settlementFun(bm_obj_data.token, bm_obj_data.settlement_data.settlement_type); } diff --git a/packkey/zfb-reduce.html b/packkey/zfb-reduce.html index 8817c22..63e6b86 100644 --- a/packkey/zfb-reduce.html +++ b/packkey/zfb-reduce.html @@ -185,14 +185,14 @@ .then(({ code, data, message }) => { // 使用结算 6 // 卡密做特殊处理,复制才会触发 - if (bm_obj_data && !bm_obj_data.settlement_data.is_settlement && bm_obj_data.settlement_data.settlement_type === 6 && self.goods.product_type !== 2) { + if (bm_obj_data && !bm_obj_data.settlement_data.is_settlement && bm_obj_data.settlement_data.settlement_type === 6) { settlementFun(bm_obj_data.token, bm_obj_data.settlement_data.settlement_type); } if (code == 200) { // 使用成功结算 7 // 直充类 上游充值返回成功 - if (bm_obj_data && !bm_obj_data.settlement_data.is_settlement && bm_obj_data.settlement_data.settlement_type === 7 && self.goods.product_type !== 2) { + if (bm_obj_data && !bm_obj_data.settlement_data.is_settlement && bm_obj_data.settlement_data.settlement_type === 7) { settlementFun(bm_obj_data.token, bm_obj_data.settlement_data.settlement_type); }