Category : livewires

Every time I do the same action request, the runtime keeps increasing. Is there any way to fix it? in my blade : <div class="col-md-6"> <div class="form-group @error(‘promotion’) has-error @enderror required"> <label>Promotion</label> <select class="full-width" wire:model="promotion" wire:change="select_promotion"> <option></option> @foreach($data_promotion as $data) <option value="{{$data->promotion_id}}" {{$promotion==$data->promotion_id?’selected’:”}}>{{$data->promotion_name}}</option> @endforeach </select> <x-jet-hold wire:loading.class="visible"></x-jet-hold> <x-jet-loading wire:loading.class="visible" wire:target="select_group"></x-jet-loading> </div> @error(‘promotion’) <label id="promotion-error" class="error" ..

Read more

I’m trying to have a select in a modal, in order to have a contact formular in my application. The view is ok, the select is here, but when I select one of the options, the modal close and block everything. I’m in a livewire component. Resume.php namespace AppHttpLivewireSimulation; use LivewireComponent; use AppModelsContributor; use AppModelsCourse; ..

Read more

i stack with livewire Update with checkbox array please help. Form <form wire:submit.prevent="Update" class="py-3 mb-6"> @foreach ($permissions as $key => $pms) <input type="checkbox" model:wire="PermissionCheckbox.{{ $key }}" {{ in_array($pms->id , $PermissionCheckbox)? "checked":"" }} /> @endforeach <button class="btn btn-primary" type="submit">Update</button> </form> Php Function public function Edit($id){ $role = Role::find($id); $this->roleId = $role->id; $this->roleName = $role->name; $this->PermissionCheckbox = ..

Read more

There are 3 livewire components UserIsExpired, UserIsActive and UserIsPending and 3 buttons respective to each component. When a button is clicked, it should replace previous component with its respective component. <button wire:click="$emit(active)">{{ __(‘Active’) }}</button> <button wire:click="$emit(pending)">{{ __(‘Pending’) }}</button> <button wire:click="$emit(expired)">{{ __(‘Expired’) }}</button> In view <livewire:user-is-active :active="$active"/> <livewire:user-is-pending :pending="$pending"/> <livewire:user-is-expired :expired="$expired"/> Component example class UserIsExpired extends ..

Read more

I am using Livewire and Slect2 in my project and I am code to select 2 javascript also but select 2 value is not passed to the database here is my code My Blade File <div class="col-12 col-lg-12 col-sm-12"> <div wire:ignore> <div class="form-group"> <label for="exampleInputRounded0">Section Name</label> <div class="input-group"> <div class="input-group-prepend"> <span class="input-group-text"><i class="fas fa-globe-asia text-primary"></i></span> ..

Read more

<select class="form-control" wire:model.defer="production_parametre_fixes_id.0" wire:change="showUnite(0)"> <option value="0">Choisir</option> @foreach ($list_parametres as $item) <option value="{{ $item->id }}"> @if ($item->etape = ‘Réception’) {{ $item->matiere }} | {{ $item->unite }} @endif </option> @endforeach </select> <input type="text" class="form-control" placeholder=" " wire:model.defer="qte_materiel.0"/> <input type="time" class="form-control" placeholder=" " wire:model.defer="debut.0"/> I have select from database and I want to Show only input for quantite ..

Read more

I have a select2 in a livewire component. Everything works fine but in my edit view, the selected options dont show in the box as selected. When I open the dropdown they show as highlighted, so data is coming from backend. <div wire:ignore class="col-8"> <select wire:model="notificationType" class="form-control select2 text-sm" multiple="multiple"> @foreach($notificationTypeOptions as $key => $option) ..

Read more

composer require livewire/livewire Using version ^2.3 for livewire/livewire ./composer.json has been updated Loading composer repositories with package information Updating dependencies (including require-dev) PHP Fatal error: Allowed memory size of 1610612736 bytes exhausted (tried to allocate 4096 bytes) in phar://C:/ProgramData/ComposerSetup/bin/composer.phar/src/Composer/DependencyResolver/RuleWatchGraph.php on line 52 Fatal error: Allowed memory size of 1610612736 bytes exhausted (tried to allocate 4096 ..

Read more

I use laravel 8. I define protected namespace in RouteServiceProvider: protected $namespace = ‘AppHttpControllers’; then the route: Route::get(‘/xxx’ , AppHttpLivewireCounter::class); but I have the below error : Invalid route action: [AppHttpControllersAppHttpLivewireCounter]. Is there a way for me to have both ‍controller protected namespace (for controller namespace) and a Route::get for Full-Page Components? Sourc..

Read more

I have problem with nesting component when changing the children parent is refresh and its ok, but when I add same product in CartItem by using barcode the quantity dose not change in child component this my parent Component including a table parent.blade.php >>> <table class="table mb-0"> <thead> <tr> <th scope="col">product</th> <th>price</th> <th>quantity</th> </tr> </thead> ..

Read more