This commit is contained in:
Lemuel Marquez
2021-06-29 09:55:18 -05:00
parent 1d071bbe31
commit b84c1312fc
5 changed files with 28 additions and 9 deletions
+4 -1
View File
@@ -26,7 +26,10 @@ const cancelar = async (body) => {
);
})
.then((res) =>
Prestamo.update({ activo: false }, { where: { idPrestamo } })
Prestamo.update(
{ activo: false, cancelado: true },
{ where: { idPrestamo } }
)
)
.then((res) => ({ message: 'Se cancelo el prestamo correctamente.' }));
};