skip to Main Content

JavaScript dialog delete error in Laravel 9

I want to create a confirmation dialog in JavaScript before deleting an item. My JavaScript code function confirmerSuppression() { var confirmation = confirm("Êtes-vous sûr de vouloir supprimer cet élément ?"); if (confirmation) { window.location.href = '/tiers.destroy/' + id; // }…

VIEW QUESTION

Verify email in Laravel 9

I want to do email verification. Actually, it succeeded, but only to the email in the .env file. Why didn't other users receive the email verification link? Model class User extends Authenticatable implements MustVerifyEmail web Auth::routes(['verify' => true]); controller $this->middleware(['auth',…

VIEW QUESTION

Laravel migration to change an unsignedMediumInteger column

I have a need to create a migration that changes an existing 'unsignedMediumInteger' column to nullable(). I have the following in my migration: <?php use IlluminateDatabaseMigrationsMigration; use IlluminateDatabaseSchemaBlueprint; use IlluminateSupportFacadesSchema; use AppNewModelsSubscriptionType; return new class extends Migration { public function…

VIEW QUESTION

Some relations returning NULL when using UUID as ID – Laravel Eloquent

Why do some of my voucher relations return null? even though there is a voucher with that ID And some relationships run well as in the picture below This is code for dumping the results dump(AppModelsAffiliatorVoucher::find('27a4093d-2370-4c55-bc44-1f8ef8144067')->toArray()); dd(AppModelsAffiliatorVoucherMember::with('voucher')->find(172)->toArray()); AppModelsAffiliatorVoucher class AffiliatorVoucher…

VIEW QUESTION

Laravel – request->filled method can not see parameter, which exists within request data

In web.php file I have route like this: Route::get('/list/{list_id}/edit', [ListingController::class, 'edit']); Then in ListingController: public function edit(Request $request) { var_dump($request->list_id); var_dump($request->filled('list_id')); exit; } If url is like: domain.com/list/20/edit result is: string(2) "20" bool(false) So $request->list_id exists but $request->filled('list_id') gives FALSE.…

VIEW QUESTION

Sending mail from event and listener in laravel 9

I have the following method in laravel my controller: use AppEventsContactFormSubmitted; public function submitContactForm(Request $request) { $validatedData = $request->validate([ 'name' => 'required|string|max:255', 'email' => 'required|email|max:255', 'subject' => 'required|string|max:255', 'message' => 'required|string', ]); // Dispatch the event with the validated data…

VIEW QUESTION
Back To Top
Search