diff --git a/src/programa/programa.service.ts b/src/programa/programa.service.ts index 83ff5ad..7694eb3 100644 --- a/src/programa/programa.service.ts +++ b/src/programa/programa.service.ts @@ -13,6 +13,8 @@ import { ValidacionService } from 'src/helpers.services/validacion.service'; import { AuthService } from 'src/auth/auth.service'; import { gmail } from 'src/helpers.services/gmail.service'; import { SendMailDto } from 'src/helpers.services/dto/send-email.dto'; +const { enviarSec } = require('../helpers.services/msjCorreos'); + @Injectable() export class ProgramaService { @@ -71,12 +73,15 @@ export class ProgramaService { //Agregamos esta linea para verificar los logs console.log("Password generado:", this.authService.generarPassword()); console.log("prog:", prog); - + if (!responsable) { const password = await this.authService.encriptar( - this.authService.generarPassword(), + await this.authService.generarPassword(), ); + + + const correoInfo = enviarSec(password, prog.correo, prog.nombre); responsable = await this.usuarioRepo.create({