Files
aibuddytool/routes/web.php
Charles T 36efe23dcc Add (routes): All routes possible
Add (pages): home country page
2023-07-26 03:10:36 +08:00

40 lines
1.6 KiB
PHP

<?php
use Illuminate\Support\Facades\Route;
/*
|--------------------------------------------------------------------------
| Web Routes
|--------------------------------------------------------------------------
|
| Here is where you can register web routes for your application. These
| routes are loaded by the RouteServiceProvider and all of them will
| be assigned to the "web" middleware group. Make something great!
|
*/
Route::get('/', [App\Http\Controllers\Front\HomeController::class, 'index'])->name('home');
Route::get('/{country}', [App\Http\Controllers\Front\HomeController::class, 'country'])->name('home.country');
Route::get('/{country}/posts', [App\Http\Controllers\Front\HomeController::class, 'posts'])->name('home.country.posts');
Route::get('/{country}/posts/{post}', [App\Http\Controllers\Front\HomeController::class, 'post'])->name('home.country.post');
Route::get('/{country}/{category}', [App\Http\Controllers\Front\HomeController::class, 'countryCategory'])->name('home.country.category');
Auth::routes();
Route::prefix('admin')->middleware('auth')->group(function () {
Route::get('/', [App\Http\Controllers\Admin\DashboardController::class, 'index'])->name('dashboard');
Route::view('about', 'admin.about')->name('about');
Route::get('users', [\App\Http\Controllers\Admin\UserController::class, 'index'])->name('users.index');
Route::get('profile', [\App\Http\Controllers\Admin\ProfileController::class, 'show'])->name('profile.show');
Route::put('profile', [\App\Http\Controllers\Admin\ProfileController::class, 'update'])->name('profile.update');
});