editar institución admin corregido
This commit is contained in:
@@ -74,9 +74,7 @@ export class ModuloController {
|
||||
@Serealize(OnlyModuloOutputDto)
|
||||
@Get('modulos')
|
||||
@UseGuards(AuthGuard('jwt'))
|
||||
@ApiOperation({
|
||||
description: 'Todos los módulos de una institución.',
|
||||
})
|
||||
@ApiOperation({ description: 'Todos los módulos de una institución.' })
|
||||
@ApiBearerAuth('jwt')
|
||||
modulos(@Request() req, @Query() query: IdInstitucionDto) {
|
||||
const superAdmin: Operador = req.user.operador;
|
||||
|
||||
@@ -132,6 +132,7 @@ export class OperadorService {
|
||||
return this.fullInformacionOperadorView
|
||||
.findAndCount({
|
||||
where: busqueda,
|
||||
order: { operador: 'ASC' },
|
||||
take: 25,
|
||||
skip: (parseInt(filtros.pagina) - 1) * 25,
|
||||
})
|
||||
@@ -164,6 +165,7 @@ export class OperadorService {
|
||||
return this.repository.find({
|
||||
select: ['id_operador', 'operador'],
|
||||
where: { institucion: admin.institucion },
|
||||
order: { operador: 'ASC' },
|
||||
});
|
||||
}
|
||||
|
||||
@@ -215,7 +217,6 @@ export class OperadorService {
|
||||
): Promise<{ message: string }> {
|
||||
return this.findById(id_operador)
|
||||
.then((operador) => {
|
||||
console.log(operador);
|
||||
this.validarUpdate(admin, operador);
|
||||
// Generamos un password por si no se mando uno
|
||||
if (!password) password = this.bcryptService.generarPassword();
|
||||
|
||||
@@ -113,7 +113,7 @@ export class UploadFileController {
|
||||
@ApiBody({
|
||||
schema: {
|
||||
type: 'object',
|
||||
properties: { csv: { type: 'string', format: 'binary' } },
|
||||
properties: { logo: { type: 'string', format: 'binary' } },
|
||||
},
|
||||
})
|
||||
uploadLogo(@Request() req, @UploadedFile() file: Express.Multer.File) {
|
||||
|
||||
Reference in New Issue
Block a user