From ffc5027789b241e8653527e9dd373fed35c57bd0 Mon Sep 17 00:00:00 2001 From: Lizandro Guarnizo <77708265+lizandrogd@users.noreply.github.com> Date: Sat, 9 Mar 2024 17:03:51 -0500 Subject: [PATCH] Update ShowPlanes.php --- app/Http/Livewire/ShowPlanes.php | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/app/Http/Livewire/ShowPlanes.php b/app/Http/Livewire/ShowPlanes.php index 99080f5..c5da3b9 100755 --- a/app/Http/Livewire/ShowPlanes.php +++ b/app/Http/Livewire/ShowPlanes.php @@ -95,7 +95,7 @@ class ShowPlanes extends Component public $activoHoy; public $libres = null; - public $delete_1 = ['1']; + public $delete_1 = []; public $tarifas; public $addUser; public $usuarios; @@ -717,7 +717,13 @@ class ShowPlanes extends Component } public function seleccionarTodos(){ - $this->delete_1 = array_column($this->cont['data'], 'id'); + + if (count($this->delete_1)== 0) { + $this->delete_1 = array_column($this->cont['data'], 'id'); + } else { + $this->delete_1 = []; + } + //dd($this->delete_1); }