Move initialization function to composer
git-svn-id: https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/uoa-connect-portal/trunk@54459 d315682c-612b-4755-9ff5-7f18f6832af3
This commit is contained in:
parent
535bcec34d
commit
7516d60e35
|
@ -46,7 +46,7 @@ export class InviteComponent implements OnInit {
|
|||
|
||||
private ckeditorContent: string;
|
||||
|
||||
public defaultBody ='';
|
||||
// public defaultBody ='';
|
||||
|
||||
public communityIdParam = {};
|
||||
public status: number = 1;
|
||||
|
@ -86,11 +86,8 @@ export class InviteComponent implements OnInit {
|
|||
this.fullname = Session.getUserFullName();
|
||||
console.log("Fullname from session " + Session.getUserFullName());
|
||||
|
||||
this.defaultBody = Composer.initializeInvitationEmailsBody(this.communityId, this.community.title);
|
||||
|
||||
// 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.body = Composer.initializeInvitationsBody(this.communityId, this.community.title, this.fullname);
|
||||
this.email = Composer.initializeInvitationsEmail(community.title);
|
||||
this.recipients = "";
|
||||
|
||||
this.status = this.errorCodes.DONE;
|
||||
|
@ -133,8 +130,8 @@ export class InviteComponent implements OnInit {
|
|||
this.successfulSentMessage = res + " email sent successfully!";
|
||||
}
|
||||
|
||||
this.body = {fromMessage: ", on behalf of ", fromName: this.fullname, paragraphs: this.defaultBody, signature: "OpenAIRE team", note: ""};
|
||||
this.email = {body: "", subject: "[OpenAIRE-Connect] " + this.community.title, recipients: []};
|
||||
this.body = Composer.initializeInvitationsBody(this.communityId, this.community.title, this.fullname);
|
||||
this.email = Composer.initializeInvitationsEmail(this.community.title);
|
||||
this.recipients = "";
|
||||
},
|
||||
error => {
|
||||
|
|
Loading…
Reference in New Issue