From 535bcec34d82a4a6437c0c285ec6eccc377b83e5 Mon Sep 17 00:00:00 2001 From: "sofia.baltzi" Date: Tue, 18 Dec 2018 12:56:54 +0000 Subject: [PATCH] Move email's body initialization to library git-svn-id: https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/uoa-connect-portal/trunk@54446 d315682c-612b-4755-9ff5-7f18f6832af3 --- .../utils/subscribe/invite/invite.component.ts | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/src/app/utils/subscribe/invite/invite.component.ts b/src/app/utils/subscribe/invite/invite.component.ts index 581bf5a..ca03dee 100644 --- a/src/app/utils/subscribe/invite/invite.component.ts +++ b/src/app/utils/subscribe/invite/invite.component.ts @@ -85,16 +85,15 @@ export class InviteComponent implements OnInit { this.community = community; this.fullname = Session.getUserFullName(); console.log("Fullname from session " + Session.getUserFullName()); - this.defaultBody = '

You are invited to subscribe to ' + this.community.title + ' dashboard.' - + '
The purpose of this dashboard is to gather, link & monitor the research results related to your community.

' - + '

The community dashboard is part of the OpenAIRE-Connect project and currently is in BETA version.

'; - // TODO move the initialisation - this.body = {fromMessage: ", on behalf of ", fromName: this.fullname, paragraphs: this.defaultBody, signature: "OpenAIRE team", note: ""}; - this.email = {body: "", subject: "[OpenAIRE-Connect] " + community.title, recipients: []}; - this.recipients = ""; + this.defaultBody = Composer.initializeInvitationEmailsBody(this.communityId, this.community.title); - this.status = this.errorCodes.DONE; + // TODO move the initialisation + this.body = {fromMessage: ", on behalf of ", fromName: this.fullname, paragraphs: this.defaultBody, signature: "OpenAIRE team", note: ""}; + this.email = {body: "", subject: "[OpenAIRE-Connect] " + community.title, recipients: []}; + this.recipients = ""; + + this.status = this.errorCodes.DONE; }, error => this.handleError(error) );