我也是这个问题 ,老是报这个errMsg: "authorize:fail 系统错误,错误码:-12007,scope unauthorized" [代码]wx.authorize({[代码][代码] [代码][代码]scope: [代码][代码]'scope.userInfo'[代码][代码],[代码][代码] [代码][代码]success(res){[代码][代码] [代码][代码]console.log([代码][代码]'pppp'[代码][代码], res)[代码][代码] [代码][代码]wx.getUserInfo({[代码][代码] [代码][代码]success:res=>{[代码][代码] [代码][代码]console.log([代码][代码]'pppp'[代码][代码],res)[代码][代码] [代码][代码]wx.setStorage({[代码][代码] [代码][代码]key: [代码][代码]'permissions'[代码][代码],[代码][代码] [代码][代码]data: res,[代码][代码] [代码][代码]})[代码][代码] [代码][代码]}[代码][代码] [代码] [代码] [代码][代码]})[代码][代码] [代码][代码]}, fail: err => {[代码][代码] [代码][代码]wx.showToast({[代码][代码] [代码][代码]title: [代码][代码]'失败'[代码][代码],[代码][代码] [代码][代码]})[代码][代码] [代码][代码]console.error([代码][代码]'失败:'[代码][代码], err)[代码][代码] [代码][代码]}[代码][代码] [代码][代码]})[代码][代码] [代码][代码]}[代码]
急!调用wx.authorize 返回12007错误{errMsg: "authorize:fail scope unauthorized", errCode: "-12007"} errCode:"-12007" errMsg:"authorize:fail scope unauthorized" __proto__:Object [图片] 用户机型:苹果7plus [图片] 代码部分: wx.login({ success: function () { wx.getUserInfo({ withCredentials: true, success: function (res) { //此处为获取微信信息后的业务方法 that.globalData.userInfo = res.userInfo; typeof cb == "function" && cb(that.globalData.userInfo) }, fail: function () { //获取用户信息失败后。请跳转授权页面 wx.showModal({ title: '警告', content: '尚未进行授权,请点击确定跳转到授权页面进行授权。', success: function (res) { if (res.confirm) { console.log('用户点击确定') wx.navigateTo({ url: '/pages/tologin/tologin', }) } },fail(e){ console.log("用户授权失败") console.log(e); } }) } }) } });
2019-08-27