model:iPhone 7<iPhone9,1> pixelRatio:2 windowWidth:375 windowHeight:667 language:zh_CN version:7.0.4 platform:ios 我用了WEPY,代碼片段怎麼搞?
IOS退出小程序後再進入會卡死1、第一次進入 調用 wx.openBluetoothAdapter 正常 2、用 <navigator class="leave-btn" open-type="exit" target="miniProgram" @tap="alreadyLeave">已離場</navigator> 退出小程序 3、再次打開進入 卡死了, 無法 調用 this.initBluetooth() 裡面的 wx.openBluetoothAdapter onShow() { this.getAppAuth() console.log('start up on show ', moment().format('YYYY-MM-DD HH:mm:ss')) if (this.init === false) { // 預防進入兩次,小程序機制bug this.init = true const value = wx.getStorageSync('WXOpenId') console.log('value ', value) if (value) { globalStore.wxOpenId = value } if (globalStore.wxOpenId === ''){ getToken(this.loginWX(), this.getTokenSuccess, this.getTokenFail); } else{ wx.getSystemInfo({ success: res => { console.log('model:' + res.model) console.log('pixelRatio:' + res.pixelRatio) console.log('windowWidth:' + res.windowWidth) console.log('windowHeight:' + res.windowHeight) console.log('language:' + res.language) console.log('version:' + res.version) console.log('platform:' + res.platform) globalStore.phoneSystem = res.platform globalStore.phoneSystemVersion = res.version if(globalStore.phoneSystem === 'devtools'){ globalStore.devParkType === '1' ? this.isMarkLocation() : wx.redirectTo({ url: 'confirm-info' }) } else{ this.initBluetooth() } }, fail: res => { // curThis.bleError = res.errCode + ' ' + res.errMsg; } }) } } }
2019-06-03我也碰到这问题,我这要3-4秒才能取到。可能是微信用户量太大,服务器配得不够吧。
小程序通过code获取openID接口好慢通过下面接口获取 openID,每次都要1.2秒,是微信服务器的问题还是我的环境问题 [代码]https://api.weixin.qq.com/sns/jscode2session?appid=APPID&secret=SECRET&js_code=JSCODE&grant_type=authorization_code[代码]
2019-05-24