From 21e872e7fe45bbab3ef1da035a1c99b3d4f869e9 Mon Sep 17 00:00:00 2001 From: lizandrogd <77708265+lizandrogd@users.noreply.github.com> Date: Sat, 11 May 2024 12:27:07 -0500 Subject: [PATCH] Update ShowUsuarios.php --- app/Http/Livewire/ShowUsuarios.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/Http/Livewire/ShowUsuarios.php b/app/Http/Livewire/ShowUsuarios.php index 9e63bfa..5742238 100755 --- a/app/Http/Livewire/ShowUsuarios.php +++ b/app/Http/Livewire/ShowUsuarios.php @@ -216,9 +216,9 @@ class ShowUsuarios extends Component $recarga->valor_recarga = $this->valor_recargar; $recarga->save(); - + $nuevo_saldo = $this->saldo_actual + (int)$this->valor_recargar; $this->consulta_saldo->update([ - 'valor' => $this->saldo_actual + (int)$this->valor_recargar + 'valor' => $nuevo_saldo, ]); $usuario_a_recargar = User::find($this->user_saldo); @@ -227,7 +227,7 @@ class ShowUsuarios extends Component //Log de recarga de saldo s $logsGeneral = new Log_general(); $logsGeneral->user_id = Auth::user()->id; - $logsGeneral->detalle = 'El usuario ' . Auth::user()->name . ' - ' . Auth::user()->email . ' ha recargado a ' . $nombre. ' - ' . $email . ' la cantidad de $' . $this->valor_recargar.', Nuevo saldo disponible: $'.$this->saldo_actual; + $logsGeneral->detalle = 'El usuario ' . Auth::user()->name . ' - ' . Auth::user()->email . ' ha recargado a ' . $nombre. ' - ' . $email . ' la cantidad de $' . $this->valor_recargar.', Nuevo saldo disponible: $'.$nuevo_saldo; $logsGeneral->save(); $this->alert('success', 'Saldo actualizado con exito!', [