scope列表中只有userinfo
发布于 7 年前 作者 eyang 4722 次浏览 来自 问答

测试代码:

permission: function () {

    wx.getSetting({

      success: function (res) {

        console.log(res.authSetting[‘scope.userInfo’]);

        console.log(res.authSetting[‘scope.userLocation’]);

        console.log(res.authSetting[‘scope.address’]);

        console.log(res.authSetting[‘scope.invoiceTitle’]);

        console.log(res.authSetting[‘scope.werun’]);

        console.log(res.authSetting[‘scope.record’]);

        console.log(res.authSetting[‘scope.writePhotosAlbum’]);

        console.log(res.authSetting[‘scope.camera’]);

      }

    })

  }

控制台显示的信息:

用wx.openSetting打开授权设置页面后也只有获取用户信息的选项求助

1 回复

你要之前申请过授权的项目才会显示,直接调用是不会把所有都列出来的

回到顶部