added new alerts and modified restrictions to the lock
This commit is contained in:
@@ -161,6 +161,18 @@ export default function AddTime({
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
if (numericValue > 10000) {
|
||||
toast.error("El monto no puede superar $10000.00");
|
||||
Swal.fire({
|
||||
title:
|
||||
"El monto no puede superar $10000.00 pesos",
|
||||
icon: "error",
|
||||
draggable: true,
|
||||
});
|
||||
return;
|
||||
}
|
||||
|
||||
setAmount(value);
|
||||
}
|
||||
}}
|
||||
@@ -187,9 +199,8 @@ export default function AddTime({
|
||||
|
||||
<button
|
||||
type="button"
|
||||
className={`button buttonCancel ${
|
||||
lock ? "buttonLock" : "buttonOpenLock"
|
||||
}`}
|
||||
className={`button buttonCancel ${lock ? "buttonLock" : "buttonOpenLock"
|
||||
}`}
|
||||
onClick={() => {
|
||||
setLock((prev) => !prev);
|
||||
setAmount("");
|
||||
|
||||
@@ -220,6 +220,18 @@ export default function Inscripcion({
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
if (numericValue > 10000) {
|
||||
toast.error("El monto no puede superar $10000.00");
|
||||
Swal.fire({
|
||||
title:
|
||||
"El monto no puede superar $10000.00 pesos",
|
||||
icon: "error",
|
||||
draggable: true,
|
||||
});
|
||||
return;
|
||||
}
|
||||
|
||||
setAmount(value);
|
||||
}
|
||||
}}
|
||||
@@ -243,9 +255,8 @@ export default function Inscripcion({
|
||||
<button className="button buttonSearch">Inscribir</button>
|
||||
<button
|
||||
type="button"
|
||||
className={`button buttonCancel ${
|
||||
lock ? "buttonLock" : "buttonOpenLock"
|
||||
}`}
|
||||
className={`button buttonCancel ${lock ? "buttonLock" : "buttonOpenLock"
|
||||
}`}
|
||||
onClick={() => {
|
||||
setLock((prev) => !prev);
|
||||
setAmount("");
|
||||
|
||||
@@ -120,6 +120,23 @@ function Receipt({ numAcount }: ReceiptsProps) {
|
||||
|
||||
if (lock && numericValue > 1000) {
|
||||
toast.error("El monto no puede superar $1000.00");
|
||||
Swal.fire({
|
||||
title:
|
||||
"El monto no puede superar $1000.00 Desbloquea el candado !",
|
||||
icon: "error",
|
||||
draggable: true,
|
||||
});
|
||||
return;
|
||||
}
|
||||
|
||||
if (numericValue > 10000) {
|
||||
toast.error("El monto no puede superar $10000.00");
|
||||
Swal.fire({
|
||||
title:
|
||||
"El monto no puede superar $10000.00 pesos",
|
||||
icon: "error",
|
||||
draggable: true,
|
||||
});
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user