ya multo en caso de que se demore en entregar el equipo
This commit is contained in:
@@ -18,10 +18,9 @@ const multar = async (body) => {
|
||||
);
|
||||
let prestamo = {};
|
||||
let fechaFin = moment();
|
||||
|
||||
return Operador.findOne({ where: { idOperador: idOperadorMulta } })
|
||||
.then((res) => {
|
||||
if (!res) throw new Error('No existe esta este operador.');
|
||||
if (!res) throw new Error('No existe este operador.');
|
||||
return Infraccion.findOne({ where: { idInfraccion } });
|
||||
})
|
||||
.then((res) => {
|
||||
@@ -55,7 +54,9 @@ const multar = async (body) => {
|
||||
idPrestamo,
|
||||
})
|
||||
)
|
||||
.then((res) => ({ message: `Se levantó correctamente el reporte de multa.` }));
|
||||
.then((res) => ({
|
||||
message: `Se levantó correctamente el reporte de multa.`,
|
||||
}));
|
||||
};
|
||||
|
||||
module.exports = multar;
|
||||
|
||||
Reference in New Issue
Block a user