Allow user to set country

This commit is contained in:
Nabeel Shahzad
2018-01-09 19:08:16 -06:00
parent af646ff8d8
commit 78912f2f31
8 changed files with 38 additions and 4 deletions

View File

@@ -73,10 +73,16 @@ class ProfileController extends AppBaseController
$airlines = $this->airlineRepo->selectBoxList();
$airports = $this->airportRepo->selectBoxList();
$countries = collect((new \League\ISO3166\ISO3166)->all())
->mapWithKeys(function($item, $key) {
return [strtolower($item['alpha2']) => $item['name']];
});
return $this->view('profile.edit', [
'user' => $user,
'airlines' => $airlines,
'airports' => $airports,
'countries' => $countries,
'timezones' => Timezonelist::toArray(),
]);
}