Project

General

Profile

« Previous | Next » 

Revision 53949

Added by Sofia Baltzi over 5 years ago

Fix email's subject and body

View differences:

modules/uoa-admin-portal/trunk/src/app/pages/community/community-edit-form/community-edit-form.component.ts
240 240
          );
241 241
    }
242 242

  
243
    // TODO find the right place to write it
244
    // private composeEmailForNewManager(communityName: string, newCommunityManagers: any): Email {
245
    //     this.email.subject = "[OpenAIRE-Connect] " + communityName + ": Managers list notification";
246
    //     this.email.body = "<p>There are updates in the managers list for " + communityName + " community.<br>"
247
    //                         + "The list of managers is: " + newCommunityManagers + "</p><br><br>" +
248
    //                         "OpenAIRE team<br>" + "<a href='https://www.openaire.eu'>www.openaire.eu</a>";
249
    //     this.email.recipients = newCommunityManagers;
250
    //
251
    //     console.log(this.email);
252
    //
253
    //     return this.email;
254
    // }
255

  
256 243
    private composeEmailForNewManager(communityName: string, newCommunityManagers: any): Email {
257
        this.email.subject = "[OpenAIRE-Connect] " + communityName + ": Managers list notification";
244
        this.email.subject = "[OpenAIRE-Connect] " + communityName + ": Manager";
258 245
        this.email.body = "<div style='font-size:14px;'><p>You are receiving this e-mail as you were assigned as manager of the community  <a href='https://beta."
259 246
                            + this.communityId + ".openaire.eu/'>" + "\"" + communityName + "\"" + "</a> dashboard. "
260 247
                            + "In order to access the administration section of your community you must first login using one of the available options. "
......
275 262

  
276 263
    // TODO find the right place to write it
277 264
    private composeEmailToInformOldManagersForTheNewOnes(communityName: string, communityId: string, firstVersionOfManagers: any) : Email {
278
        this.emailToInform.subject = "[OpenAIRE-Connect]" + communityName + ": New subscriber notification";
279
        this.emailToInform.body = "<p>There is a new subscriber for " + communityName +
280
                                  "community. Click  <a href='https://beta.admin.connect.openaire.eu/manage-subscribers?communityId=" +
281
                                  communityId + "'>here</a> to manage the subscibers list.</p><br><br>" +
282
                                  "OpenAIRE team<br>"+ "<a href='https://www.openaire.eu'>www.openaire.eu</a>";
265
        this.emailToInform.subject = "[OpenAIRE-Connect] " + communityName + ": Managers list notification";
266
        this.emailToInform.body = "<p>There are updates in the managers list for \"" + communityName + "\" community.<br>"
267
                                 + "The list of managers is: " + this.community.managers + "</p><br>"
268
                                 + "OpenAIRE team<br>" + "<a href='https://www.openaire.eu'>www.openaire.eu</a>"
269
                                 + "<p style='font-size:11px;'>You are receiving this e-mail as manager of the community "
270
                                 + "<a href='https://beta." + communityId + ".openaire.eu/'>" + communityName + "</a>. "
271
                                 + "If you are not responsible for this community, please "
272
                                 + "<a href='mailto:openaire.test@gmail.com'>contact us</a>."
273
                                 + "<br>"
274
                                 + "Click  <a href='https://beta.admin.connect.openaire.eu/manage-user-notifications?communityId=" + communityId
275
                                 + "'>here</a> to manage your notification settings. </p>";
276
;
283 277
        this.emailToInform.recipients = firstVersionOfManagers;
284 278

  
285 279
        return this.emailToInform;

Also available in: Unified diff