public async Task <ListOfCountriesViewModels> GetListOfCountries(string languageId = "en-gb") { ListOfContinents listOfCotinents = await FileHelper.GetDataAsync <ListOfContinents>(FileName.PARENT_FOLDER, FileName.LIST_CONTINENTS); ListOfCountriesViewModels listOfCountriesViewModel = _skyscannerMapper.MapListOfContinentsToListOfCountiesViewModel(listOfCotinents); return(listOfCountriesViewModel); }
public async Task <ListOfCountriesViewModels> GetListOfCountries(string languageId = "en-gb") { ListOfContinents listOfCotinents = await GetFullListOfContinents(languageId); ListOfCountriesViewModels listOfCountriesViewModel = _skyscannerMapper.MapListOfContinentsToListOfCountiesViewModel(listOfCotinents); return(listOfCountriesViewModel); }
public async Task <IActionResult> Index() { string clientIpAddress = HttpContext.GetIpAddress(); ListOfPlacesViewModels listOfPlaces = await Execute(() => _skyscannerService.Location.GetPlaceByIpAddress(clientIpAddress)); ListOfCountriesViewModels listOfCountries = await Execute(() => _skyscannerService.Location.GetListOfCountries()); return(View((listOfCountries, listOfPlaces))); }