Code Monkey home page Code Monkey logo

Comments (8)

orthuslee avatar orthuslee commented on July 27, 2024

locType:167的话是因为在android6+上需要处理动态权限,把targetsdk改为22或者在增加对动态权限的处理即可。

from cordova-plugin-baidumaplocation.

orthuslee avatar orthuslee commented on July 27, 2024

试了下,在5.1下出现和你一样的问题505,\n
"locTypeDescription": "NetWork location failed because baidu location service check the key is unlegal,
please check the key in AndroidManifest.xml !",\n "latitude": 5e-324,\n "lontitude": 5e-324,\n
"radius": 0,\n "userIndoorState": -1,\n "direction": -1\n}

from cordova-plugin-baidumaplocation.

itshu avatar itshu commented on July 27, 2024

跟android版本有关?低版本的不适配吗?

from cordova-plugin-baidumaplocation.

itshu avatar itshu commented on July 27, 2024

有没有解决办法?

from cordova-plugin-baidumaplocation.

orthuslee avatar orthuslee commented on July 27, 2024

发现是SHA1的问题,我用了这个检查到的SHA1和keystool获取的不一样,在百度的api控制台,修改SHA1后OK。你试试看是不是这个问题导致
191344gbo4snpsn48r4bnb

from cordova-plugin-baidumaplocation.

orthuslee avatar orthuslee commented on July 27, 2024

另外在sdk大于等于23以上的时候,是有问题的,只能降低版本,一直出现 locType:167,动态权限导致问题,需要在插件中处理申请动态权限

from cordova-plugin-baidumaplocation.

itshu avatar itshu commented on July 27, 2024

申请动态权限,我就不知道怎么弄了,我先看看上面那个,多谢

from cordova-plugin-baidumaplocation.

KevinWang15 avatar KevinWang15 commented on July 27, 2024

@itshu @orthuslee 我实现了 Android 6.0+ 动态权限的支持,已发PR,可以先用我的试试看
https://github.com/KevinWang15/cordova-plugin-baidumaplocation

cordova plugin rm cordova-plugin-baidumaplocation
cordova plugin add https://github.com/KevinWang15/cordova-plugin-baidumaplocation --variable ANDROID_KEY="..." --variable IOS_KEY="..."

from cordova-plugin-baidumaplocation.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.