Airport Editing

This commit is contained in:
portree_kid
2020-01-08 22:05:39 +01:00
parent 9a59509638
commit 753d77e52f
2 changed files with 14 additions and 3 deletions
+4 -3
View File
@@ -88,12 +88,13 @@
bounds.getSouthWest().lng < Number(coordinates[0])
return ret && ret2
},
// Triggered by adding airports to the map
addEvent (event, item) {
// console.log(event, item)
if (item.properties.groundnet === 0) {
event.target.setStyle({color: 'red', fillcolor: 'red'})
} else if ((item.properties.flights / item.properties.parking) > 10) {
event.target.setStyle({color: 'yellow', fillcolor: 'yellow'})
event.target.setStyle({color: 'red', fillColor: 'red'})
} else if ((item.properties.flights / item.properties.parking) > 40) {
event.target.setStyle({color: 'yellow', fillColor: 'yellow'})
}
},
onClick (item) {