Update ShowPlanes.php
This commit is contained in:
@@ -238,6 +238,8 @@ class ShowPlanes extends Component
|
||||
}
|
||||
public function saveRenovar()
|
||||
{
|
||||
$correo_existe = Cuentas::where('correo', $this->usuario_renovar)->exists();
|
||||
if (!$correo_existe) {
|
||||
if ($this->fecha_inicial_renovar_old !== $this->fecha_inicial_renovar || $this->fecha_final_renovar_old !== $this->fecha_final_renovar) {
|
||||
$this->alert('warning', '¿Desea también desvincular todos los usuarios de esta cuenta? ', [
|
||||
'position' => 'center',
|
||||
@@ -271,14 +273,22 @@ class ShowPlanes extends Component
|
||||
'detalle' => 'El usuario ha editado el usuario de la cuenta ' . $cuenta_renovar->correo
|
||||
]);
|
||||
}
|
||||
|
||||
$this->alert('success', 'Cuenta actualizada correctamente!', [
|
||||
'position' => 'top'
|
||||
]);
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
$this->renovar = false;
|
||||
$this->ver = false;
|
||||
}
|
||||
} else {
|
||||
$this->alert('warning', 'Esta cuenta ya existe!', [
|
||||
'position' => 'top'
|
||||
]);
|
||||
}
|
||||
}
|
||||
public function siRenovar()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user