getLocation我同意获取了,为什么每次开发工具上都弹出框
发布于 5 年前 作者 hejun 2631 次浏览 来自 问答

getPosition: function (openid) {

var that = this;

wx.getLocation({

type: ‘gcj02’,

success: function (res) {

that.setData({

nearLon: res.longitude,

nearLat: res.latitude,

},function(){

that.loadData(openid, res.longitude, res.latitude);

})

},

fail: function (res) {

console.log(‘没有允许定位!获取失败!’);

// that.loadData(openid, 113.264435, 23.129163);

},

complete: function () {

that.setData({ loadHidden: true });

}

})

},

第一次已经同意获取了,为什么后来调用这个,在开发工具上还得一直点击同意

4 回复

最新今天(2018-12-28)发布的新版开发工具

1.02.1812271

已经解决了每次都弹出授权提示框的问题

可以看看昨天关于getlocation的更新

 同问  这个很烦人  原先没有,更新后一直弹出

回到顶部