phpvms/resources/js/admin/airport_lookup.js
Nabeel S 09f3e3cfdf
Set the baseURL for ajax requests (#373)
* Set the baseURL for ajax requests

* Use async/await on AJAX calls

* Add mix_public() cache generated asset cache busting

* Move storage container into separate class

* Fix some styling
2019-08-27 15:08:42 -04:00

18 lines
343 B
JavaScript

'use strict';
/**
* Lookup an airport from the server
*
* @param {String} icao
*/
export default async (icao) => {
let params = {
method: 'GET',
url: '/api/airports/' + icao + '/lookup',
};
const response = await axios(params);
console.log('lookup raw response: ', response);
return response.data;
};