wx.getUserProfile回调只fail?
wx.login({ success: function (res) { var vcode = res.code; console.log('login code:' + vcode); console.log(that.data.canIUseGetUserProfile) if (vcode) { console.log(11) wx.getUserProfile({ desc:'用于获取头像昵称', success: function (resp) { console.log('getUserInfo successd........'); var encryptedData = encodeURIComponent(resp.encryptedData); me.ajaxPost('/user/login', { tuiuid: me.appQuery.shareuid, code: vcode, encryptData: resp.encryptedData, iv: resp.iv, }, function (ret) { wx.hideLoading(); console.log(ret.sdata); console.log(ret); if (ret.errcode == 0) { try { me.gUser = ret.sdata me.cache().set('loginUser', ret.sdata) cb && cb(true) } catch (e) { cb && cb(false) console.log(e) } } else { console.log(ret.msg) } }) }, fail: function (res) { wx.hideLoading() console.log('getUserInfo fail:未授权'); console.log(res); } }) }