merge axel

This commit is contained in:
2026-03-03 17:41:06 -06:00
parent 22431dd73e
commit 04290f4097
@@ -25,16 +25,17 @@ export class DetalleServicioController {
return this.detalleServicioService.findByDateRange(data.desde, data.hasta);
}
@Get('totales-por-periodo')
async getTotalesPorPeriodo(
@Query('periodoInicio') periodoInicio?: string,
@Query('periodoFin') periodoFin?: string,
@Query('servicioId') servicioId?: string,
) {
const inicio = periodoInicio ? parseInt(periodoInicio) : undefined;
const fin = periodoFin ? parseInt(periodoFin) : undefined;
const servicio = servicioId ? parseInt(servicioId) : undefined;
return this.detalleServicioService.getTotalesPorServicioYPeriodo(inicio, fin, servicio);
}
@UseGuards(JwtAuthGuard, RolesGuard)
@Roles(Role.ADMINISTRADOR, Role.SUPER_ADMINISTRADOR)
@Get('totales-por-periodo')
async getTotalesPorPeriodo(
@Query('periodoInicio') periodoInicio?: string,
@Query('periodoFin') periodoFin?: string,
@Query('servicioId') servicioId?: string,
) {
const inicio = periodoInicio ? parseInt(periodoInicio) : undefined;
const fin = periodoFin ? parseInt(periodoFin) : undefined;
const servicio = servicioId ? parseInt(servicioId) : undefined;
return this.detalleServicioService.getTotalesPorServicioYPeriodo(inicio, fin, servicio);
}
}