Showing
1 changed file
with
2 additions
and
1 deletions
... | ... | @@ -305,6 +305,7 @@ |
305 | 305 | const markerList: MarkerList[] = []; |
306 | 306 | data.forEach((item) => { |
307 | 307 | const { |
308 | + alias, | |
308 | 309 | name, |
309 | 310 | deviceState, |
310 | 311 | deviceInfo: { longitude, latitude }, |
... | ... | @@ -313,7 +314,7 @@ |
313 | 314 | const rivet = deviceState === 'INACTIVE' ? djx : deviceState === 'ONLINE' ? zx : lx; |
314 | 315 | const myIcon = new BMap.Icon(rivet, new BMap.Size(20, 30)); |
315 | 316 | const marker = new BMap.Marker(point, { icon: myIcon }); |
316 | - const label = new BMap.Label(name, { | |
317 | + const label = new BMap.Label(alias || name, { | |
317 | 318 | position: point, |
318 | 319 | offset: new BMap.Size(-15, -45), |
319 | 320 | }); | ... | ... |