From f4809f753d1a1a772c994ba2845b5ffb84c55567 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BD=90=E5=A4=A9=E5=A4=A7=E5=9C=A3?= <17615834396@163.com> Date: Wed, 27 Mar 2024 10:12:45 +0800 Subject: [PATCH] sn --- gasStation-uni/App.vue | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/gasStation-uni/App.vue b/gasStation-uni/App.vue index 37c22f8dd..e3e520d52 100644 --- a/gasStation-uni/App.vue +++ b/gasStation-uni/App.vue @@ -3,7 +3,7 @@ onLaunch: function(e) { console.log('App Launch') // #ifdef MP-WEIXIN - uni.setStorageSync("appltType","WECHAT") + uni.setStorageSync("appltType", "WECHAT") console.log("微信") //检查是否存在新版本 uni.getUpdateManager().onCheckForUpdate(function(res) { @@ -39,21 +39,22 @@ }); // #endif // #ifdef MP-ALIPAY - uni.setStorageSync("appltType","ALIPAY") + uni.setStorageSync("appltType", "ALIPAY") console.log("支付宝") my.canIUse('button.open-type.getAuthorize') //获取关联普通二维码的码值,放到全局变量qrCode中 if (e.query && e.query.qrCode) { - console.log(JSON.stringify(e)+"1.0") - let q = e.query.qrCode; + console.log(JSON.stringify(e) + "1.0") + let q = e.query.qrCode; if (e.query.qrCode) { let str = q.split("?")[1]; let storeId = ""; - + let staffId = ""; let userId = ""; let type = ""; - if (str.includes("&")){ + let sn = ""; + if (str.includes("&")) { let arr = str.split("&"); arr.forEach(item => { if (item.includes("storeId")) { @@ -64,9 +65,11 @@ userId = item.split("=")[1] } else if (item.includes("type")) { type = item.split("=")[1] + } else { + sn = item.split("=")[1] } }) - }else{ + } else { if (str.includes("storeId")) { storeId = str.split("=")[1] } @@ -79,7 +82,7 @@ // title:uni.getStorageSync("storeId") + "staffId" + uni.getStorageSync("inviteStaffId") // }) } - } + } // #endif }, onShow: function() { @@ -99,4 +102,4 @@ .dis { display: flex; } - \ No newline at end of file +