Files
airline-agency/routes/web.php
T

36 lines
1.3 KiB
PHP

<?php
use App\Http\Controllers\Account\EditProfileController;
use App\Http\Controllers\Account\ProfileController;
use App\Http\Controllers\FlightController;
use App\Http\Controllers\IndexController;
use App\Http\Controllers\TourController;
use Illuminate\Support\Facades\Route;
Route::get('/' , [IndexController::class , 'index'])->name('index');
Route::prefix('flights')->controller(FlightController::class)->name('flights.')->group(function (){
Route::get('/' , 'index')->name('index');
Route::get('{flight}','show')->name('show');
});
Route::prefix('tours')->controller(TourController::class)->name('tours.')->group(function (){
Route::get('/' , 'index')->name('index');
Route::get('{tour}','show')->name('show');
});
Route::prefix('account')->name('accounts.')->middleware('auth')->group(function (){
Route::controller(ProfileController::class)->group(function () {
Route::get('/profile', 'index')->name('profile');
Route::get('/get-cities/{province_id}', 'getCities')->name('get-cities');
});
Route::prefix('edit-profile')->name('edit-profile.')->controller(EditProfileController::class)->group(function () {
Route::get('/', 'index')->name('index');
Route::post('/', 'update')->name('update');
Route::post('change-password', 'changePassword')->name('change-password');
});
});