更新记录

1.0.0(2023-03-12)

制作原因

uni.chooseLocation()不支持谷歌地图POI搜索

使用方法

注意

manifest.json 打开定位

引入组件

<genos-googlemap ref="googlemap" googleKey="谷歌KEY" lang="cn" @confirmAddress="confirmAddress"></genos-googlemap>

打开弹窗

this.$refs.googlemap.open();

接收返回
confirmAddress(e){
    console.log(e);
}

参数说明

参数 默认 说明
googleKey 谷歌地图官方web key
lang cn https://developers.google.com/maps/faq?hl=zh-cn#languagesupport

返回说明

{
    "compound_code": "中国北京市海淀区",
    "latlng": {
        "lat": 39.986913000000001,
        "lng": 116.30587389999999
    },
    "name": "北京大学"
}
参数 说明
compound_code 行政区划
latlng 经纬度
name 名称

平台兼容性

genos-googlemap

隐私、权限声明

1. 本插件需要申请的系统权限列表:

定位

2. 本插件采集的数据、发送的服务器地址、以及数据用途说明:

3. 本插件是否包含广告,如包含需详细说明广告表达方式、展示频率:

许可协议

MIT协议

使用中有什么不明白的地方,就向插件作者提问吧~ 我要提问