Fix formatting and interfaces in nearly every file

This commit is contained in:
Nabeel Shahzad
2018-03-19 20:50:40 -05:00
parent 04c5b9e7bf
commit ccf56ddec1
331 changed files with 3282 additions and 2492 deletions

View File

@@ -4,9 +4,9 @@
*/
Route::group([
'namespace' => 'Admin', 'prefix' => 'admin', 'as' => 'admin.',
'middleware' => ['role:admin'],
], function () {
'namespace' => 'Admin', 'prefix' => 'admin', 'as' => 'admin.',
'middleware' => ['role:admin'],
], function () {
Route::resource('airlines', 'AirlinesController');
Route::match(['get', 'post', 'put'], 'airports/fuel', 'AirportController@fuel');
@@ -60,7 +60,7 @@ Route::group([
Route::resource('users', 'UserController');
Route::get('users/{id}/regen_apikey',
'UserController@regen_apikey')->name('users.regen_apikey');
'UserController@regen_apikey')->name('users.regen_apikey');
# defaults
Route::get('', ['uses' => 'DashboardController@index']);
@@ -68,6 +68,6 @@ Route::group([
Route::get('dashboard', ['uses' => 'DashboardController@index', 'name' => 'dashboard']);
Route::match(['get', 'post', 'delete'],
'dashboard/news', ['uses' => 'DashboardController@news'])
'dashboard/news', ['uses' => 'DashboardController@news'])
->name('dashboard.news');
});

View File

@@ -3,8 +3,7 @@
/**
* Public routes
*/
Route::group([], function()
{
Route::group([], function () {
Route::get('acars', 'AcarsController@index');
Route::get('pireps/{pirep_id}/acars/geojson', 'PirepController@acars_geojson');
@@ -15,8 +14,7 @@ Route::group([], function()
/**
* these need to be authenticated with a user's API key
*/
Route::group(['middleware' => ['api.auth']], function ()
{
Route::group(['middleware' => ['api.auth']], function () {
Route::get('airlines', 'AirlineController@index');
Route::get('airlines/{id}', 'AirlineController@get');
@@ -79,5 +77,4 @@ Route::group(['middleware' => ['api.auth']], function ()
Route::get('users/{id}/bids', 'UserController@bids');
Route::put('users/{id}/bids', 'UserController@bids');
});

View File

@@ -1,12 +1,11 @@
<?php
/**
* User doesn't need to be logged in for these
*/
Route::group([
'namespace' => 'Frontend', 'prefix' => '', 'as' => 'frontend.'
], function() {
], function () {
Route::get('/', 'HomeController@index')->name('home');
Route::get('r/{id}', 'PirepController@show')->name('pirep.show.public');
Route::get('p/{id}', 'ProfileController@show')->name('profile.show.public');
@@ -21,7 +20,7 @@ Route::group([
* These are only visible to a logged in user
*/
Route::group([
'namespace' => 'Frontend', 'prefix' => '', 'as' => 'frontend.',
'namespace' => 'Frontend', 'prefix' => '', 'as' => 'frontend.',
'middleware' => ['role:admin|user'],
], function () {
Route::resource('dashboard', 'DashboardController');