提交 37574356 编写于 作者: 杜庆泉's avatar 杜庆泉

腾讯定位发布配置添加

上级 ce930e42
## 1.0.0(2023-09-11)
基于腾讯定位服务,实现uni.getLocation 获取定位功能
......@@ -2,13 +2,13 @@
"id": "uni-getLocation-tencent",
"displayName": "uni-getLocation-tencent",
"version": "1.0.0",
"description": "uni-getLocation-tencent",
"description": "基于腾讯定位服务,实现uni.getLocation 获取定位功能",
"keywords": [
"uni-getLocation-tencent"
],
"uni-getLocation-tencent"
],
"repository": "",
"engines": {
"HBuilderX": "^3.6.11"
"HBuilderX": "^3.8.12"
},
"dcloudext": {
"type": "uts",
......@@ -24,59 +24,65 @@
"qq": ""
},
"declaration": {
"ads": "",
"data": "",
"permissions": ""
"ads": "",
"data": "插件使用的 腾讯定位SDK会采集数据,详情可参考:https://lbs.qq.com/",
"permissions": "<!-- 通过GPS得到精确位置 -->\n\t<uses-permission android:name=\"android.permission.ACCESS_FINE_LOCATION\"/>\n\t<!-- 通过网络得到粗略位置 -->\n\t<uses-permission android:name=\"android.permission.ACCESS_COARSE_LOCATION\"/>\n\t<!-- 访问网络,某些位置信息需要从网络服务器获取 -->\n\t<uses-permission android:name=\"android.permission.INTERNET\"/>\n\t<!-- 访问WiFi状态,需要WiFi信息用于网络定位 -->\n\t<uses-permission android:name=\"android.permission.ACCESS_WIFI_STATE\"/>\n\t<!-- 修改WiFi状态,发起WiFi扫描, 需要WiFi信息用于网络定位 -->\n\t<uses-permission android:name=\"android.permission.CHANGE_WIFI_STATE\"/>\n\t<!-- 访问网络状态, 检测网络的可用性,需要网络运营商相关信息用于网络定位 -->\n\t<uses-permission android:name=\"android.permission.ACCESS_NETWORK_STATE\"/>\n\t<!-- 访问网络的变化, 需要某些信息用于网络定位 -->\n\t<uses-permission android:name=\"android.permission.CHANGE_NETWORK_STATE\"/>\n\t<!-- 蓝牙扫描权限 -->\n\t<uses-permission android:name=\"android.permission.BLUETOOTH\"/>\n\t<uses-permission android:name=\"android.permission.BLUETOOTH_ADMIN\"/>\n\t<!-- 前台service权限 -->\n\t<uses-permission android:name=\"android.permission.FOREGROUND_SERVICE\"/>\n\t<!-- 后台定位权限 -->\n\t<uses-permission android:name=\"android.permission.ACCESS_BACKGROUND_LOCATION\"/>\n\t<!-- A-GPS辅助定位权限,方便GPS快速准确定位 -->\n\t<uses-permission android:name=\"android.permission.ACCESS_LOCATION_EXTRA_COMMANDS\"/>\n"
},
"npmurl": ""
},
"uni_modules": {
"uni-ext-api": {
"uni": ["getLocation"]
"uni": [
"getLocation"
]
},
"dependencies": [],
"encrypt": [],
"platforms": {
"cloud": {
"tcb": "u",
"aliyun": "u"
"tcb": "y",
"aliyun": "y"
},
"client": {
"Vue": {
"vue2": "n",
"vue2": "y",
"vue3": "y"
},
"App": {
"app-android": "u",
"app-ios": "u"
"app-android": {
"minVersion": "19"
},
"app-ios": {
"minVersion": "9"
}
},
"H5-mobile": {
"Safari": "u",
"Android Browser": "u",
"微信浏览器(Android)": "u",
"QQ浏览器(Android)": "u"
"Safari": "n",
"Android Browser": "n",
"微信浏览器(Android)": "n",
"QQ浏览器(Android)": "n"
},
"H5-pc": {
"Chrome": "u",
"IE": "u",
"Edge": "u",
"Firefox": "u",
"Safari": "u"
"Chrome": "n",
"IE": "n",
"Edge": "n",
"Firefox": "n",
"Safari": "n"
},
"小程序": {
"微信": "u",
"阿里": "u",
"百度": "u",
"字节跳动": "u",
"QQ": "u",
"钉钉": "u",
"快手": "u",
"飞书": "u",
"京东": "u"
"微信": "n",
"阿里": "n",
"百度": "n",
"字节跳动": "n",
"QQ": "n",
"钉钉": "n",
"快手": "n",
"飞书": "n",
"京东": "n"
},
"快应用": {
"华为": "u",
"联盟": "u"
"华为": "n",
"联盟": "n"
}
}
}
......
......@@ -2,6 +2,6 @@
"dependencies": [
"com.tencent.map.geolocation:TencentLocationSdk-openplatform:7.3.0"
],
"minSdkVersion": 21
"minSdkVersion": "19"
}
......@@ -37,7 +37,7 @@ export const getLocation : GetLocation = function (options : GetLocationOptions)
/**
* 准备权限
*/
let permissionNeed : string[] = utsArrayOf("android.permission.ACCESS_FINE_LOCATION");
let permissionNeed = ["android.permission.ACCESS_FINE_LOCATION"];
UTSAndroid.requestSystemPermission(UTSAndroid.getUniActivity()!, permissionNeed, function (allRight:boolean,_grantedList:string[]) {
if (allRight) {
// 交给目前的location 引擎,真实执行
......
{
"deploymentTarget": "9"
}
\ No newline at end of file
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册