mirror of
https://github.com/mewtek/i2ME-Legacy.git
synced 2025-05-11 00:57:31 -05:00
Add national airport codes to getAirportCodes()
This commit is contained in:
parent
cfca3d718a
commit
47fe9a9c47
@ -50,9 +50,90 @@ def getTideStations():
|
|||||||
|
|
||||||
def getAirportCodes():
|
def getAirportCodes():
|
||||||
""" Returns all of the airport identifiers present in the MachineProductCfg """
|
""" Returns all of the airport identifiers present in the MachineProductCfg """
|
||||||
airports = []
|
airports = [
|
||||||
|
'ATL',
|
||||||
|
'LAX',
|
||||||
|
'ORD',
|
||||||
|
'DFW',
|
||||||
|
'JFK',
|
||||||
|
'DEN',
|
||||||
|
'SFO',
|
||||||
|
'CLT',
|
||||||
|
'LAS',
|
||||||
|
'PHX',
|
||||||
|
'IAH',
|
||||||
|
'MIA',
|
||||||
|
'SEA',
|
||||||
|
'EWR',
|
||||||
|
'MCO',
|
||||||
|
'MSP',
|
||||||
|
'DTW',
|
||||||
|
'BOS',
|
||||||
|
'PHL',
|
||||||
|
'LGA',
|
||||||
|
'FLL',
|
||||||
|
'BWI',
|
||||||
|
'IAD',
|
||||||
|
'MDW',
|
||||||
|
'SLC',
|
||||||
|
'DCA',
|
||||||
|
'HNL',
|
||||||
|
'SAN',
|
||||||
|
'TPA',
|
||||||
|
'PDX',
|
||||||
|
'STL',
|
||||||
|
'HOU',
|
||||||
|
'BNA',
|
||||||
|
'AUS',
|
||||||
|
'OAK',
|
||||||
|
'MSY',
|
||||||
|
'RDU',
|
||||||
|
'SJC',
|
||||||
|
'SNA',
|
||||||
|
'DAL',
|
||||||
|
'SMF',
|
||||||
|
'SAT',
|
||||||
|
'RSW',
|
||||||
|
'PIT',
|
||||||
|
'CLE',
|
||||||
|
'IND',
|
||||||
|
'MKE',
|
||||||
|
'CMH',
|
||||||
|
'OGG',
|
||||||
|
'PBI',
|
||||||
|
'BDL',
|
||||||
|
'CVG',
|
||||||
|
'JAX',
|
||||||
|
'ANC',
|
||||||
|
'BUF',
|
||||||
|
'ABQ',
|
||||||
|
'ONT',
|
||||||
|
'OMA',
|
||||||
|
'BUR',
|
||||||
|
'OKC',
|
||||||
|
'MEM',
|
||||||
|
'PVD',
|
||||||
|
'RIC',
|
||||||
|
'SDF',
|
||||||
|
'RNO',
|
||||||
|
'TUS',
|
||||||
|
'CHS',
|
||||||
|
'ORF',
|
||||||
|
'PWM',
|
||||||
|
'GRR',
|
||||||
|
'BHM',
|
||||||
|
'LIT',
|
||||||
|
'DSM',
|
||||||
|
'FAR',
|
||||||
|
'FSD',
|
||||||
|
'ICT',
|
||||||
|
'LBB',
|
||||||
|
'BIL',
|
||||||
|
'BOI',
|
||||||
|
'GEG'
|
||||||
|
]
|
||||||
for i in data['Config']['ConfigDef']['ConfigItems']['ConfigItem']:
|
for i in data['Config']['ConfigDef']['ConfigItems']['ConfigItem']:
|
||||||
if "Airport" in i['@key'] and i['@value'] != "":
|
if "Airport" in i['@key'] and i['@value'] != "" and not i['@value'] in airports:
|
||||||
# Split the string up
|
# Split the string up
|
||||||
airports.append(i['@value'].split("_")[2])
|
airports.append(i['@value'].split("_")[2])
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user