From 22ee7183363dade0bb04139a4965df7f5752a974 Mon Sep 17 00:00:00 2001 From: Samir Date: Thu, 6 Jun 2019 01:51:14 +0200 Subject: [PATCH 1/8] SSO user invite emails update --- emails/src/partials/invites.html | 124 ++++++++++++++++--------------- 1 file changed, 65 insertions(+), 59 deletions(-) diff --git a/emails/src/partials/invites.html b/emails/src/partials/invites.html index f616a14..6936d43 100644 --- a/emails/src/partials/invites.html +++ b/emails/src/partials/invites.html @@ -24,73 +24,79 @@ + {{#if [isSSO]}} - - - + + + + + + + + + + - - +
+ + + + + +
You have been invited to a project by {{initiator.firstName}} {{initiator.lastName}}. Please use the link below to sign in and join the project.
+
+ + +
+
+ - + + -
You have been invited to a project by {{initiator.firstName}} {{initiator.lastName}}. To join, please register with Topcoder. + + SSO Login + +
-
+ + + + {{else}} + + + + + + + +
You have been invited to a project by {{initiator.firstName}} {{initiator.lastName}}. To join, please register with Topcoder.
+ + - - - - -
- - - - - - - - - - -
- - Register - -
- - - - - - -
- - - - - + + + + + - - - - +
+ + +
+
+ - + + -
If you are enterprise client with SSO, please use the link below to sign in and join the project. + + Register + +
-
- - - - - - -
- - SSO Login - -
-
+ + + {{/if}} + From cd583471976ff3977c2682934630df233b06a423 Mon Sep 17 00:00:00 2001 From: gondzo Date: Fri, 7 Jun 2019 07:31:12 +0200 Subject: [PATCH 2/8] Update template for sso users --- emails/src/partials/project-team.html | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/emails/src/partials/project-team.html b/emails/src/partials/project-team.html index bb250e3..adcc9f5 100644 --- a/emails/src/partials/project-team.html +++ b/emails/src/partials/project-team.html @@ -58,7 +58,11 @@ {{userFullName}} joined the project {{/if}} {{#if [notifications.connect.project.member.invite.created]}} + {{#if [isSSO]}} + Hi {{userFullName}}, you are invited to join the project {{projectName}}. Please use the link below to sign in and join the project. + {{else}} Hi {{userFullName}}, you are invited to join the project {{projectName}}. Please click on the button ("View project on Connect") below to join. + {{/if}} {{/if}} {{#if [notifications.connect.project.member.invite.requested]}} You are requested to add {{userFullName}} as a copilot @@ -107,9 +111,15 @@ Manage project team {{else}} + {{#if [isSSO]}} + + SSO Login + + {{else}} View project on Connect + {{/if}} {{/if}} From 5cc72a8a3bf101ce7b8fc7a396ab01d1be93e9bd Mon Sep 17 00:00:00 2001 From: gondzo Date: Sat, 8 Jun 2019 09:15:37 +0200 Subject: [PATCH 3/8] Update project-team.html --- emails/src/partials/project-team.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/emails/src/partials/project-team.html b/emails/src/partials/project-team.html index adcc9f5..e9a5dc1 100644 --- a/emails/src/partials/project-team.html +++ b/emails/src/partials/project-team.html @@ -111,7 +111,7 @@ Manage project team {{else}} - {{#if [isSSO]}} + {{#if notifications.[0].[isSSO]}} SSO Login From 91f1390b5dfab5d856a505255494b79b5a8c67c6 Mon Sep 17 00:00:00 2001 From: gondzo Date: Thu, 11 Jul 2019 12:18:16 +0200 Subject: [PATCH 4/8] Update email.js --- connect/notificationServices/email.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/connect/notificationServices/email.js b/connect/notificationServices/email.js index cdcdaa2..182fc6b 100644 --- a/connect/notificationServices/email.js +++ b/connect/notificationServices/email.js @@ -98,6 +98,7 @@ function handleScheduledEvents(events, setEventsStatus) { const bundleData = { subject: 'Your Topcoder project updates', connectURL: config.CONNECT_URL, + accountsAppURL: config.get('accountsAppUrl'), projects: _.chain(userEvents) .groupBy('data.data.projectId') .mapValues(projectUserEvents => ({ @@ -165,6 +166,7 @@ function wrapIndividualNotification(data) { return { subject, connectURL: config.CONNECT_URL, + accountsAppURL: config.get('accountsAppUrl'), projects: [{ id: data.data.data.projectId, name: data.data.data.projectName, From f612bfd296e42f5e3241d3a83843dfb97a25c40d Mon Sep 17 00:00:00 2001 From: gondzo Date: Thu, 11 Jul 2019 12:20:19 +0200 Subject: [PATCH 5/8] Update config.js --- connect/config.js | 1 + 1 file changed, 1 insertion(+) diff --git a/connect/config.js b/connect/config.js index e0b2ab6..896905d 100644 --- a/connect/config.js +++ b/connect/config.js @@ -35,4 +35,5 @@ module.exports = { DEFAULT_REPLY_EMAIL: process.env.DEFAULT_REPLY_EMAIL, CONNECT_URL: process.env.CONNECT_URL || 'https://connect.topcoder-dev.com', + "ACCOUNTS_APP_URL": process.env.ACCOUNTS_APP_URL || "https://accounts.topcoder-dev.com", }; From 7ef960b50daa5e19e79e5749aad16abacb0b3880 Mon Sep 17 00:00:00 2001 From: gondzo Date: Thu, 11 Jul 2019 12:20:30 +0200 Subject: [PATCH 6/8] Update config.js --- connect/config.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/connect/config.js b/connect/config.js index 896905d..f2c414a 100644 --- a/connect/config.js +++ b/connect/config.js @@ -35,5 +35,5 @@ module.exports = { DEFAULT_REPLY_EMAIL: process.env.DEFAULT_REPLY_EMAIL, CONNECT_URL: process.env.CONNECT_URL || 'https://connect.topcoder-dev.com', - "ACCOUNTS_APP_URL": process.env.ACCOUNTS_APP_URL || "https://accounts.topcoder-dev.com", + ACCOUNTS_APP_URL: process.env.ACCOUNTS_APP_URL || "https://accounts.topcoder-dev.com", }; From e6ebe2830a6178a39d35198f77991e786a6c66ab Mon Sep 17 00:00:00 2001 From: gondzo Date: Thu, 11 Jul 2019 12:21:53 +0200 Subject: [PATCH 7/8] Update email.js --- connect/notificationServices/email.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/connect/notificationServices/email.js b/connect/notificationServices/email.js index 182fc6b..16a6b07 100644 --- a/connect/notificationServices/email.js +++ b/connect/notificationServices/email.js @@ -98,7 +98,7 @@ function handleScheduledEvents(events, setEventsStatus) { const bundleData = { subject: 'Your Topcoder project updates', connectURL: config.CONNECT_URL, - accountsAppURL: config.get('accountsAppUrl'), + accountsAppURL: config.get('ACCOUNTS_APP_URL'), projects: _.chain(userEvents) .groupBy('data.data.projectId') .mapValues(projectUserEvents => ({ @@ -166,7 +166,7 @@ function wrapIndividualNotification(data) { return { subject, connectURL: config.CONNECT_URL, - accountsAppURL: config.get('accountsAppUrl'), + accountsAppURL: config.get('ACCOUNTS_APP_URL'), projects: [{ id: data.data.data.projectId, name: data.data.data.projectName, From 4970e582653894aeb3c8fceae804612f28624705 Mon Sep 17 00:00:00 2001 From: gondzo Date: Thu, 11 Jul 2019 12:44:57 +0200 Subject: [PATCH 8/8] Update email.js --- connect/notificationServices/email.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/connect/notificationServices/email.js b/connect/notificationServices/email.js index 16a6b07..99cce30 100644 --- a/connect/notificationServices/email.js +++ b/connect/notificationServices/email.js @@ -98,7 +98,7 @@ function handleScheduledEvents(events, setEventsStatus) { const bundleData = { subject: 'Your Topcoder project updates', connectURL: config.CONNECT_URL, - accountsAppURL: config.get('ACCOUNTS_APP_URL'), + accountsAppURL: config.ACCOUNTS_APP_URL, projects: _.chain(userEvents) .groupBy('data.data.projectId') .mapValues(projectUserEvents => ({ @@ -166,7 +166,7 @@ function wrapIndividualNotification(data) { return { subject, connectURL: config.CONNECT_URL, - accountsAppURL: config.get('ACCOUNTS_APP_URL'), + accountsAppURL: config.ACCOUNTS_APP_URL, projects: [{ id: data.data.data.projectId, name: data.data.data.projectName,