middleware(['auth', 'verified'])->name('dashboard'); Route::middleware('auth')->group(function () { Route::get('/profile', [ProfileController::class, 'edit'])->name('profile.edit'); Route::patch('/profile', [ProfileController::class, 'update'])->name('profile.update'); Route::delete('/profile', [ProfileController::class, 'destroy'])->name('profile.destroy'); }); require __DIR__ . '/auth.php'; Auth::routes(); Route::get('/home', [App\Http\Controllers\HomeController::class, 'index'])->name('home'); //DataTables Route::get('/datatables', function () { return view('backend.datatables'); }); //Email //Route::post('/send-email', [MailController::class, 'sendEmail']); Route::post('/send-email', [UserController::class, 'StoreUser'])->name('send-email'); Route::get('/all-user', [App\Http\Controllers\backend\UserController::class, 'AllUser'])->name('alluser'); Route::get('/add-user', [App\Http\Controllers\backend\UserController::class, 'AddUser'])->name('adduser'); Route::post('/store-user', [App\Http\Controllers\backend\UserController::class, 'StoreUser'])->name('storeuser'); Route::get('/edit-user/{id}', [App\Http\Controllers\backend\UserController::class, 'EditUser'])->name('edituser'); Route::post('/update-user/{id}', [App\Http\Controllers\backend\UserController::class, 'UpdateUser'])->name('updateuser'); Route::delete('/delete-user/{id}', [App\Http\Controllers\backend\UserController::class, 'DeleteUser'])->name('deleteuser'); Route::get('/send-email-form', [App\Http\Controllers\backend\UserController::class, 'ShowEmailForm'])->name('show-email-form'); Route::post('/send-email', [App\Http\Controllers\backend\UserController::class, 'SendEmail'])->name('send-email'); // Route for setting the locale Route::get('/lang/{locale}', function ($locale) { Session::put('locale', $locale); return redirect()->back(); })->name('setLocale'); Route::get('set-locale/{locale}', [App\Http\Controllers\LocaleController::class, 'setLocale'])->name('setLocale');