Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Android App端高德定位问题 uni.getLocation #146

Open
bb168ll opened this issue Jul 19, 2022 · 0 comments
Open

Android App端高德定位问题 uni.getLocation #146

bb168ll opened this issue Jul 19, 2022 · 0 comments

Comments

@bb168ll
Copy link

bb168ll commented Jul 19, 2022

问题描述
1.使用HBuilder3.4.18.20220630,直接运行安装到真机(华为荣耀8X)上,uni.getLocation获取定位信息正确,能获取到address
2.使用HBuilder3.4.18.20220630,生成本地打包App资源,放到androidstudio中打生产包,打包出来后安装到手机,使用uni.getLocation获取经纬度与直接运行相比偏差(800米)很大,并且无法获取得到 address

复现步骤
uni.getLocation({
type: "gcj02",
geocode: true,
altitude: true,
isHighAccuracy: true,
success: function (res){
console.log(res)
}})

预期结果
打包定位获取到的坐标信息跟运行获取的定位信息相差不大

实际结果
[这里请贴上你的报错截图或文字]

系统信息:

  • 发行平台: [如 微信小程序、H5平台、5+ App等]
  • 操作系统 [如 iOS 12.1.2、Android 7.0]
  • HBuilderX版本 [如使用HBuilderX,则需提供 HBuilderX 版本号]
  • uni-app版本 [如使用Vue-cli创建/运行项目,则提供npm run info的运行结果]
  • 设备信息 [如 荣耀8X JSN-AL00a] HarmonyOS 2.0.0

补充信息
严格按照打包流程处理的
问题不出在高德key,已经对比了n次高德key了

@dcloudio dcloudio deleted a comment from GaaChun Jun 29, 2023
@zhetengbiji zhetengbiji transferred this issue from dcloudio/uni-app Jun 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant