crud user
This commit is contained in:
8
routes/console.php
Normal file
8
routes/console.php
Normal file
@ -0,0 +1,8 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Foundation\Inspiring;
|
||||
use Illuminate\Support\Facades\Artisan;
|
||||
|
||||
Artisan::command('inspire', function () {
|
||||
$this->comment(Inspiring::quote());
|
||||
})->purpose('Display an inspiring quote')->hourly();
|
31
routes/web.php
Normal file
31
routes/web.php
Normal file
@ -0,0 +1,31 @@
|
||||
<?php
|
||||
|
||||
use App\Http\Controllers\UserController;
|
||||
use Illuminate\Support\Facades\Route;
|
||||
|
||||
//Route::get('/', function () {
|
||||
// return view('welcome');
|
||||
//});
|
||||
|
||||
Route::get('/hello', function () {
|
||||
return "<h1>Hello World</h1>";
|
||||
});
|
||||
|
||||
Route::get('/', function () {
|
||||
return view('welcome');
|
||||
});
|
||||
|
||||
Route::group(['prefix' => 'admin'], function () {
|
||||
Route::group(['prefix' => 'user'], function () {
|
||||
Route::get('/', [UserController::class, 'actionIndex']);
|
||||
Route::get('/page/{page_number}', [UserController::class, 'actionIndex']);
|
||||
Route::get('/view/{id}', [UserController::class, 'actionView']);
|
||||
Route::get('/create', [UserController::class, 'actionCreate']);
|
||||
Route::post('/store', [UserController::class, 'actionStore']);
|
||||
Route::get('/update/{id}', [UserController::class, 'actionUpdate']);
|
||||
Route::post('/edit/{id}', [UserController::class, 'actionEdit']);
|
||||
Route::get('/delete/{id}', [UserController::class, 'actionDelete']);
|
||||
});
|
||||
});
|
||||
|
||||
|
Reference in New Issue
Block a user