当前位置:网站首页>利用百度地图查询全国地铁线路
利用百度地图查询全国地铁线路
2022-07-01 05:53:00 【尼克_张】
最近做了个项目,该项目可以方便查询全国地铁线路,地铁线路上模拟小车到站提醒,点击小车可触发相关事件,使用的api 百度地图查询地铁线路 ,地铁图api,再结合vue-baidu-map
1.判断地铁线路图加载完成
this.subway.addEventListener("subwayloaded", res => {
const lines = this.subway.getLines();
})
2.点击小车触发相关事件
由于landmarkPois初始为[] ,当后面获取到数据再塞入停靠站点数据, 而vue-baidu-map中的路书会由于landmarkPois的变化而触发reload方法 ,导致两辆车出现 ,所以还是使用原生的路书
//填入路书信息
const lushu = new BMapLib.LuShu();
const length = Object.keys(lushu).length;
if (length) {
//小车id
this.markId = lushu._marker.da;
}
边栏推荐
- SystemVerilog学习-10-验证量化和覆盖率
- OneFlow源码解析:算子签名的自动推断
- 3D printer threading: five simple solutions
- Fixed height of the first column in El table dynamic header rendering
- MySQL converts milliseconds to time string
- In win10 and win11, the scroll direction of Elan touch panel is reversed, and "double finger click to open the right-click menu" and "double finger scroll" are started“
- He struggled day and night to protect his data
- Know the future of "edge computing" from the Nobel prize!
- SystemVerilog学习-07-类的继承和包的使用
- excel動態圖錶
猜你喜欢

Debug details under pycharm

3D printer threading: five simple solutions

excel动态图表

OpenGL ES: (5) OpenGL的基本概念、OpenGL ES 在屏幕产生图片的过程、OpenGL管线(pipeline)

OpenGL ES: (3) EGL、EGL绘图的基本步骤、EGLSurface、ANativeWindow

Trust guessing numbers game

OpenGL es: (5) basic concepts of OpenGL, the process of OpenGL es generating pictures on the screen, and OpenGL pipeline
![[note] e-commerce order data analysis practice](/img/03/367756437be947b5b995d5f7f55236.png)
[note] e-commerce order data analysis practice

4GB大文件,如何实时远程传输和共享?

健康照明中应用的LED照明灯
随机推荐
3D printer threading: five simple solutions
Data governance: metadata management implementation (Part IV)
PLA不粘貼在床上:6個簡單的解决方案
Code shoe set - mt3149 · and - the data is not very strong. Violent pruning can deceive AC
SQL必会题之留存率
Beauty of Mathematics - Application of Mathematics
Send you through the data cloud
Orcle创建用户+角色
Debug details under pycharm
On the first day of the new year, 3000 Apache servers went down
穿越派 你的数据云行
Essay learning record essay multi label Global
QT write custom control - self drawn battery
POL8901 LVDS转MIPI DSI 支持旋转图像处理芯片
3D打印机穿线:5种简单的解决方案
Leetcode Max rectangle, Max square series 84 85. 221. 1277. 1725. (monotonic stack, dynamic programming)
Oracle 序列+触发器
Idea start view project port
My experience from technology to product manager
FPGA - 7系列 FPGA内部结构之Clocking -02- 时钟布线资源