pre lulu
This commit is contained in:
@@ -16,6 +16,7 @@ const serviciosAdmin = async (body) => {
|
||||
? validar.validarNumeroCuenta(body.numeroCuenta)
|
||||
: '';
|
||||
let where = {};
|
||||
let data = [];
|
||||
|
||||
if (idStatus) where.idStatus = idStatus;
|
||||
return Servicio.findAll({
|
||||
@@ -32,14 +33,14 @@ const serviciosAdmin = async (body) => {
|
||||
{ model: Carrera },
|
||||
{ model: Status },
|
||||
],
|
||||
order: [['updatedAt', 'DESC']],
|
||||
}).then((res) => {
|
||||
let data = [];
|
||||
|
||||
for (let i = pagina * 25 - 25; i < res.length && i < pagina * 25; i++)
|
||||
data.push({
|
||||
idServicio: res[i].idServicio,
|
||||
fechaInicio: res[i].fechaInicio,
|
||||
fechaFin: res[i].fechaFin,
|
||||
createdAt: res[i].createdAt,
|
||||
Usuario: {
|
||||
idUsuario: res[i].Usuario.idUsuario,
|
||||
usuario: res[i].Usuario.usuario,
|
||||
|
||||
Reference in New Issue
Block a user