使用wx.chooseLocation会出现传递的经纬度不合法是什么原因?
使用wx.getLocation,定位的地点是latitude: 17, longitude: 0
问题是我没有传递参数,我只是想在地图上获取位置和选择位置,
wxml:<button bindtap=“chooseLocation” >在地图上选择</button>
js:chooseLocation: function (e) {
wx.chooseLocation({
success: function(res) {
console.log(res)
},
})
}
返回值:
<page>
</page>
StatTimer.stub('geolocation_start'); 定位失败,请稍后重试重试传递的经纬度不合法搜索取消加载中...亲,没有更多了~200米+-加载中...亲,没有更多了~ seajs.config({ base: './js/' }); seajs.use(['index-22ca56e011.js'], function(View){ new View(); }); {{#if list}} {{#each list}} <li> <h2 class="poi-title">{{title}}</h2> <p class="poi-address">{{address}}</p> <span class="poi-latlng">{{location.lat}},{{location.lng}}</span> <span class="poi-city">{{ad_info.city}}</span> <i class="active"></i> </li> {{/each}} {{else}} <p class="no-results">o_O出错了~</p> {{/if}} {{#if list}} {{#each list}} <li> <p class="item"> <span class="poi-title">{{title}}</span> <span class="poi-address">{{address}}</span> <span class="poi-latlng">{{location.lat}},{{location.lng}}</span> <span class="poi-city">{{ad_info.city}}</span> </p> </li> {{/each}} {{else}} {{#if suggestion}} {{#each suggestion}} <li data-lat="{{pointy}}" data-lng="{{pointx}}"> <p class="item"> <span class="poi-title">{{title}}</span> <span class="poi-address">{{address}}</span> <span class="poi-latlng">{{location.lat}},{{location.lng}}</span> <span class="poi-city">{{city}}</span> </p </li> {{/each}} {{/if}} {{/if}}