This commit is contained in:
parent
5de70d6b3e
commit
61713f39e3
|
|
@ -161,6 +161,13 @@ export function allDevices(options, type, show) {
|
|||
graphicLayer.addGraphic(graphic);
|
||||
} else {
|
||||
graphic.show = show;
|
||||
graphic.setOptions({
|
||||
style: {
|
||||
image: deviceItem.isOnline
|
||||
? require(`@/assets/img/device/deviceIcon/${deviceItem.icon}.png`)
|
||||
: require(`@/assets/img/device/deviceIcon/${deviceItem.icon}-offline.png`)
|
||||
}
|
||||
});
|
||||
if (deviceItem.icon === "9") {
|
||||
graphic.setOptions({
|
||||
position: new mars3d.LngLatPoint(
|
||||
|
|
@ -203,6 +210,13 @@ export function allDevices(options, type, show) {
|
|||
graphicLayer.addGraphic(graphic);
|
||||
} else {
|
||||
graphic.show = show;
|
||||
graphic.setOptions({
|
||||
style: {
|
||||
image: item.isOnline
|
||||
? require(`@/assets/img/device/deviceIcon/${item.icon}.png`)
|
||||
: require(`@/assets/img/device/deviceIcon/${item.icon}-offline.png`)
|
||||
}
|
||||
});
|
||||
if (deviceItem.icon === "9") {
|
||||
graphic.setOptions({
|
||||
position: new mars3d.LngLatPoint(deviceItem.lon, deviceItem.lat, 0)
|
||||
|
|
|
|||
Loading…
Reference in New Issue