From 9e7ac1d91fd584c47635326ffcc75f859ef930b0 Mon Sep 17 00:00:00 2001 From: Mariela Date: Mon, 22 Aug 2022 15:04:47 -0600 Subject: [PATCH] arreglar correo de registro --- .../src/communities/communities.service.ts | 13 ------------- .../src/mails/emailCreateUserTenant.hbs | 4 ++-- servicio-usuarios/src/users/users.service.ts | 6 +----- 3 files changed, 3 insertions(+), 20 deletions(-) diff --git a/servicio-comunidad-viviendas/src/communities/communities.service.ts b/servicio-comunidad-viviendas/src/communities/communities.service.ts index 48ad87b8..fa7ed5b7 100644 --- a/servicio-comunidad-viviendas/src/communities/communities.service.ts +++ b/servicio-comunidad-viviendas/src/communities/communities.service.ts @@ -83,29 +83,16 @@ export class CommunitiesService { async saveTenant(id: string, number_house: string, ptenant_id: string) { let community = await this.findOne(id); - - console.log(ptenant_id) - await community.houses.map(house => { if (house.number_house == number_house) { if (house.tenants) { - console.log(house.tenants.tenant_id + '1') house.tenants.tenant_id = ptenant_id - console.log(house.tenants.tenant_id + '1') - console.log(house.tenants + '1') } else { let tenant = new Tenant() - tenant.tenant_id = ptenant_id; - console.log(tenant) - house.tenants = tenant; - console.log(house.tenants + '2') - } - console.log(house.tenants + '3') - house.state = "ocupada" } return house; diff --git a/servicio-notificaciones/src/mails/emailCreateUserTenant.hbs b/servicio-notificaciones/src/mails/emailCreateUserTenant.hbs index 4669d4a8..a4a7586c 100644 --- a/servicio-notificaciones/src/mails/emailCreateUserTenant.hbs +++ b/servicio-notificaciones/src/mails/emailCreateUserTenant.hbs @@ -362,7 +362,7 @@ - Logo Katoikia @@ -393,7 +393,7 @@ {{date_entry}}
-

Fue asignado en la comunidad {{community_name}} en la vivienda # {{number_house}}

+

Fue asignado en la comunidad "{{community_name}}" en la vivienda #{{number_house}}

diff --git a/servicio-usuarios/src/users/users.service.ts b/servicio-usuarios/src/users/users.service.ts index 8061479e..96c973d7 100644 --- a/servicio-usuarios/src/users/users.service.ts +++ b/servicio-usuarios/src/users/users.service.ts @@ -29,11 +29,7 @@ export class UsersService { let passwordEncriptada = Md5.init(user.password); user.password = passwordEncriptada; let userCreated = await this.userModel.create(user); - console.log(await userCreated); - let callback = await this.saveTenantNumHouse(user.community_id, user.number_house, userCreated['_id']); - - const finalValue = await lastValueFrom(callback); - const response = await finalValue['response']; + await this.saveTenantNumHouse(user.community_id, user.number_house, userCreated['_id']); let community = await this.findCommunity(user.community_id); user.community_id = community['name'];