modales de pregunta fixeados

This commit is contained in:
Felipe
2024-03-02 09:18:00 -05:00
parent eb2e3ce76c
commit 3936e185e4
3 changed files with 31 additions and 13 deletions
+12 -11
View File
@@ -5,7 +5,6 @@ namespace App\Http\Livewire;
use App\Models\Cuentas;
use App\Models\Historiale;
use App\Models\Historial_cuenta;
use App\Models\Log_general;
use App\Models\Log_historial;
use App\Models\Notificacion;
use App\Models\Pendientes;
@@ -110,6 +109,12 @@ class ShowPlanes extends Component
public $editarTarifaRol = false;
public function getListeners()
{
return [
'confirmed', 'siRenovar', 'noRenovar'
];
}
public function render()
{
@@ -209,7 +214,7 @@ class ShowPlanes extends Component
{
$this->alert('warning', '¿Desea también desvincular todos los usuarios de esta cuenta?', [
'position' => 'center',
'timer' => '10000',
'timer' => '60000',
'toast' => false,
'text' => 'Esta seguro',
'showConfirmButton' => true,
@@ -217,7 +222,8 @@ class ShowPlanes extends Component
'showDenyButton' => false,
'onDenied' => 'noRenovar',
'showCancelButton' => true,
'onDismissed' => 'noRenovar',
'allowOutsideClick' => false,
'allowEscapeKey' => false,
'cancelButtonText' => 'No, solo renovar',
'confirmButtonText' => 'Si, liberar cuenta',
]);
@@ -248,7 +254,7 @@ class ShowPlanes extends Component
{
$id = $this->id_cuentaVer;
$cuenta_renovar = Cuentas::where('id', $id)->update([
Cuentas::where('id', $id)->update([
'correo' => $this->usuario_renovar,
'password' => $this->password_renovar,
'inicio' => date('Y-m-d', strtotime(strval($this->fecha_inicial_renovar))),
@@ -256,6 +262,8 @@ class ShowPlanes extends Component
'estado' => $this->estado,
]);
$cuenta_renovar = Cuentas::find($id);
Log_historial::create([
'user_id' => Auth::user()->id,
'detalle' => 'El usuario ha renovado la cuenta ' . $cuenta_renovar->correo
@@ -269,13 +277,6 @@ class ShowPlanes extends Component
$this->ver = false;
}
public function getListeners()
{
return [
'confirmed', 'siRenovar', 'noRenovar'
];
}
/* ------------- CREAR ------------- */
public function createNewCuenta()
{