dejar de cancelar al minuto
This commit is contained in:
parent
ae770a4998
commit
f5e768ca99
@ -290,9 +290,9 @@ export class PrestamoService {
|
|||||||
id_prestamo: number | Prestamo,
|
id_prestamo: number | Prestamo,
|
||||||
): Promise<Equipo> {
|
): Promise<Equipo> {
|
||||||
const ahora = moment();
|
const ahora = moment();
|
||||||
|
|
||||||
if (this.add) ahora.add(this.add, 'h');
|
if (this.add) ahora.add(this.add, 'h');
|
||||||
|
|
||||||
const ahoraStr = ahora.format('YYYY-MM-DD');
|
const ahoraStr = ahora.format('YYYY-MM-DD');
|
||||||
const prestamo =
|
const prestamo =
|
||||||
typeof id_prestamo === 'number'
|
typeof id_prestamo === 'number'
|
||||||
@ -463,11 +463,14 @@ export class PrestamoService {
|
|||||||
}
|
}
|
||||||
|
|
||||||
findAllActivosExpirados(): Promise<Prestamo[]> {
|
findAllActivosExpirados(): Promise<Prestamo[]> {
|
||||||
|
const ahora = moment();
|
||||||
|
|
||||||
|
if (this.add) ahora.add(this.add, 'h');
|
||||||
return this.informacionPrestamoView
|
return this.informacionPrestamoView
|
||||||
.find({
|
.find({
|
||||||
where: {
|
where: {
|
||||||
activo: 1,
|
activo: 1,
|
||||||
hora_max_recoger: LessThanOrEqual(moment().toDate()),
|
hora_max_recoger: LessThanOrEqual(ahora.toDate()),
|
||||||
id_status: 2,
|
id_status: 2,
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
Loading…
Reference in New Issue
Block a user