-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor: routes have been updated according to the new version of La…
…ravel
- Loading branch information
Fahri Meral
committed
Apr 29, 2024
1 parent
f933cdb
commit df92c5f
Showing
3 changed files
with
42 additions
and
86 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,84 +1,44 @@ | ||
<?php | ||
|
||
Route::group(['prefix' => 'install', 'as' => 'LaravelInstaller::', 'namespace' => 'Smarteknoloji\SmartInstaller\Controllers', 'middleware' => ['web', 'install']], function () { | ||
Route::get('/', [ | ||
'as' => 'welcome', | ||
'uses' => 'WelcomeController@welcome', | ||
]); | ||
|
||
Route::get('environment', [ | ||
'as' => 'environment', | ||
'uses' => 'EnvironmentController@environmentMenu', | ||
]); | ||
|
||
Route::get('environment/wizard', [ | ||
'as' => 'environmentWizard', | ||
'uses' => 'EnvironmentController@environmentWizard', | ||
]); | ||
|
||
Route::post('environment/saveWizard', [ | ||
'as' => 'environmentSaveWizard', | ||
'uses' => 'EnvironmentController@saveWizard', | ||
]); | ||
|
||
Route::get('environment/classic', [ | ||
'as' => 'environmentClassic', | ||
'uses' => 'EnvironmentController@environmentClassic', | ||
]); | ||
|
||
Route::post('environment/saveClassic', [ | ||
'as' => 'environmentSaveClassic', | ||
'uses' => 'EnvironmentController@saveClassic', | ||
]); | ||
|
||
Route::get('requirements', [ | ||
'as' => 'requirements', | ||
'uses' => 'RequirementsController@requirements', | ||
]); | ||
|
||
Route::get('permissions', [ | ||
'as' => 'permissions', | ||
'uses' => 'PermissionsController@permissions', | ||
]); | ||
|
||
Route::get('database/requirements', [ | ||
'as' => 'databaseRequirements', | ||
'uses' => 'DatabaseController@requirements', | ||
]); | ||
|
||
Route::get('database', [ | ||
'as' => 'database', | ||
'uses' => 'DatabaseController@database', | ||
]); | ||
|
||
Route::get('final', [ | ||
'as' => 'final', | ||
'uses' => 'FinalController@finish', | ||
]); | ||
}); | ||
|
||
Route::group(['prefix' => 'update', 'as' => 'LaravelUpdater::', 'namespace' => 'Smarteknoloji\SmartInstaller\Controllers', 'middleware' => 'web'], function () { | ||
Route::group(['middleware' => 'update'], function () { | ||
Route::get('/', [ | ||
'as' => 'welcome', | ||
'uses' => 'UpdateController@welcome', | ||
]); | ||
|
||
Route::get('overview', [ | ||
'as' => 'overview', | ||
'uses' => 'UpdateController@overview', | ||
]); | ||
|
||
Route::get('database', [ | ||
'as' => 'database', | ||
'uses' => 'UpdateController@database', | ||
]); | ||
use Illuminate\Support\Facades\Route; | ||
use Smarteknoloji\SmartInstaller\Controllers\DatabaseController; | ||
use Smarteknoloji\SmartInstaller\Controllers\EnvironmentController; | ||
use Smarteknoloji\SmartInstaller\Controllers\FinalController; | ||
use Smarteknoloji\SmartInstaller\Controllers\PermissionsController; | ||
use Smarteknoloji\SmartInstaller\Controllers\RequirementsController; | ||
use Smarteknoloji\SmartInstaller\Controllers\UpdateController; | ||
use Smarteknoloji\SmartInstaller\Controllers\WelcomeController; | ||
|
||
Route::prefix('install') | ||
->as('LaravelInstaller::') | ||
->middleware(['web', 'install']) | ||
->group(function () { | ||
Route::get('/', [WelcomeController::class, 'welcome'])->name('welcome'); | ||
Route::get('environment', [EnvironmentController::class, 'environmentMenu'])->name('environment'); | ||
Route::get('environment/wizard', [EnvironmentController::class, 'environmentWizard'])->name('environmentWizard'); | ||
Route::post('environment/saveWizard', [EnvironmentController::class, 'saveWizard'])->name('saveWizard'); | ||
Route::get('environment/classic', [EnvironmentController::class, 'environmentClassic'])->name('environmentClassic'); | ||
Route::post('environment/saveClassic', [EnvironmentController::class, 'saveClassic'])->name('saveClassic'); | ||
Route::get('requirements', [RequirementsController::class, 'requirements'])->name('requirements'); | ||
Route::get('permissions', [PermissionsController::class, 'permissions'])->name('permissions'); | ||
Route::get('database/requirements', [DatabaseController::class, 'requirements'])->name('databaseRequirements'); | ||
Route::get('database', [DatabaseController::class, 'database'])->name('database'); | ||
Route::get('final', [FinalController::class, 'finish'])->name('final'); | ||
}); | ||
|
||
// This needs to be out of the middleware because right after the migration has been | ||
// run, the middleware sends a 404. | ||
Route::get('final', [ | ||
'as' => 'final', | ||
'uses' => 'UpdateController@finish', | ||
]); | ||
}); | ||
Route::prefix('update') | ||
->as('LaravelUpdater::') | ||
->middleware(['web']) | ||
->group(function () { | ||
Route::controller(UpdateController::class) | ||
->middleware(['update']) | ||
->group(function () { | ||
Route::get('/', 'welcome')->name('welcome'); | ||
Route::get('overview', 'overview')->name('overview'); | ||
Route::post('database', 'database')->name('database'); | ||
}); | ||
|
||
// This needs to be out of the middleware because right after the migration has been | ||
// run, the middleware sends a 404. | ||
Route::get('final', [UpdateController::class, 'finish'])->name('final'); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters