地图定位授权拒绝后再次授权android机点击不了 opensetting
发布于 4 年前 作者 xiuying14 14374 次浏览 来自 问答

这是代码片段 wechatide://minicode/RzYf0amA7C2Q



小程序


chooseLocation: function (e) {

let that = this

wx.getLocation({

type: ‘gcj02’,

success: function (res) {

wx.chooseLocation({

success: function ($res) {

that.LBS($res, that)

}

})

},

fail: function () {

myDialog.showModal({

title: “提示”,

content: “您未授权,将无法操作后续的功能,点击确定获取授权”,

confirmOpenType: “openSetting”,

success: (e) => {

if (e.detail.authSetting[‘scope.userLocation’])

wx.chooseLocation({

success: function ($res) {

that.LBS($res, that)

}

})

else

wx.getLocation({

type: ‘gcj02’,

success: function (res) {

wx.chooseLocation({

success: function ($res) {

that.LBS($res, that)

}

})

}

})

}

})

},

complete: function () { }

})

},

3 回复

华为和部分安卓 手机确实存在此问题。望尽快解决、

你好,请提供一下出现问题的机型和微信版本,以及能复现问题的简单代码片段(https://developers.weixin.qq.com/miniprogram/dev/devtools/minicode.html)。

我这测试了几部安卓机,获取地址授权,授权成功后,获取不到地址。ios的手机都可以。4部安卓手机都不行

回到顶部