se hicieron cambios
This commit is contained in:
@@ -103,6 +103,7 @@ export class ExcelController {
|
||||
return result
|
||||
}
|
||||
|
||||
console.log(result.id_movimiento)
|
||||
await this.movimientoService.updateStatus(
|
||||
result.id_movimiento,
|
||||
'SUCCESS',
|
||||
@@ -176,10 +177,18 @@ export class ExcelController {
|
||||
'descarga de csv',
|
||||
`size=${csv.length}`
|
||||
);
|
||||
let filename
|
||||
if (origen == 'CORREO') {
|
||||
filename = 'usuarios_correo.csv';
|
||||
}
|
||||
else {
|
||||
filename = 'usuarios.csv';
|
||||
}
|
||||
|
||||
return res
|
||||
.status(HttpStatus.OK)
|
||||
.header('Content-Type', 'text/csv')
|
||||
.header('Content-Disposition', 'attachment; filename="usuarios_correo.csv"')
|
||||
.header('Content-Disposition', `attachment; filename="${filename}"`)
|
||||
.send(csv);
|
||||
} catch (err) {
|
||||
await this.movimientoService.log(
|
||||
|
||||
Reference in New Issue
Block a user