[pollen] branch feature/Notification updated (fa6d20f -> e4fb282)
This is an automated email from the git hooks/post-receive script. New change to branch feature/Notification in repository pollen. See http://git.chorem.org/pollen.git from fa6d20f UI can validate email new e4fb282 improve template The 1 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "adds" were already present in the repository and have only been added to this reference. Detailed log of new commits: commit e4fb2823285b1b52c824b9b9de16258b077d864d Author: Adrien Garandel <a.garandel@dralagen.fr> Date: Tue Aug 26 11:01:19 2014 +0200 improve template Summary of changes: .../pollen/services/service/mail/EmailService.java | 6 +++++- .../services/service/mail/PollCreatedEmail.java | 9 +++++++++ .../service/mail/UserAccountCreatedEmail.java | 19 ++++++++++++++----- .../main/resources/email/PollCreatedEmail.mustache | 9 +++++++++ .../main/resources/email/PollCreatedEmail_fr.mustache | 10 ++++++++++ .../resources/email/UserAccountCreatedEmail.mustache | 4 +++- .../email/UserAccountCreatedEmail_fr.mustache | 4 +++- 7 files changed, 53 insertions(+), 8 deletions(-) -- To stop receiving notification emails like this one, please contact chorem.org SCM administrator <admin+scm@chorem.org>.
This is an automated email from the git hooks/post-receive script. New commit to branch feature/Notification in repository pollen. See http://git.chorem.org/pollen.git commit e4fb2823285b1b52c824b9b9de16258b077d864d Author: Adrien Garandel <a.garandel@dralagen.fr> Date: Tue Aug 26 11:01:19 2014 +0200 improve template --- .../pollen/services/service/mail/EmailService.java | 6 +++++- .../services/service/mail/PollCreatedEmail.java | 9 +++++++++ .../service/mail/UserAccountCreatedEmail.java | 19 ++++++++++++++----- .../main/resources/email/PollCreatedEmail.mustache | 9 +++++++++ .../main/resources/email/PollCreatedEmail_fr.mustache | 10 ++++++++++ .../resources/email/UserAccountCreatedEmail.mustache | 4 +++- .../email/UserAccountCreatedEmail_fr.mustache | 4 +++- 7 files changed, 53 insertions(+), 8 deletions(-) diff --git a/pollen-services/src/main/java/org/chorem/pollen/services/service/mail/EmailService.java b/pollen-services/src/main/java/org/chorem/pollen/services/service/mail/EmailService.java index 705f2a3..773aae3 100644 --- a/pollen-services/src/main/java/org/chorem/pollen/services/service/mail/EmailService.java +++ b/pollen-services/src/main/java/org/chorem/pollen/services/service/mail/EmailService.java @@ -123,6 +123,8 @@ public class EmailService extends PollenServiceSupport { PollCreatedEmail email = new PollCreatedEmail(locale); email.setPoll(poll); + email.setPollenUrl(getPollenUIUrlRenderService().getPollenUrl()); + PollenEntityId<Poll> pollId = PollenEntityId.newId(Poll.class); pollId.setEntityId(poll.getTopiaId()); pollId.encode(serviceContext.getTopiaApplicationContext().getTopiaIdFactory()); @@ -180,11 +182,13 @@ public class EmailService extends PollenServiceSupport { email.setUser(user); email.setPassword(password); + email.setPollenUrl(getPollenUIUrlRenderService().getPollenUrl()); + PollenEntityId<PollenUser> userId = PollenEntityId.newId(PollenUser.class); userId.setEntityId(user.getTopiaId()); userId.encode(serviceContext.getTopiaApplicationContext().getTopiaIdFactory()); - email.setUrl(getPollenUIUrlRenderService().getUserValidateUrl(userId.getReducedId(), user.getEmailActivationToken().getToken())); + email.setValidateUrl(getPollenUIUrlRenderService().getUserValidateUrl(userId.getReducedId(), user.getEmailActivationToken().getToken())); return email; } diff --git a/pollen-services/src/main/java/org/chorem/pollen/services/service/mail/PollCreatedEmail.java b/pollen-services/src/main/java/org/chorem/pollen/services/service/mail/PollCreatedEmail.java index e96a727..60f8977 100644 --- a/pollen-services/src/main/java/org/chorem/pollen/services/service/mail/PollCreatedEmail.java +++ b/pollen-services/src/main/java/org/chorem/pollen/services/service/mail/PollCreatedEmail.java @@ -37,6 +37,7 @@ public class PollCreatedEmail extends PollenMail { protected Poll poll; + protected String pollenUrl; protected String url; protected PollCreatedEmail(Locale locale) { @@ -60,6 +61,14 @@ public class PollCreatedEmail extends PollenMail { return url; } + public String getPollenUrl () { + return pollenUrl; + } + + public void setPollenUrl (String pollenUrl) { + this.pollenUrl = pollenUrl; + } + public void setUrl (String url) { this.url = url; } diff --git a/pollen-services/src/main/java/org/chorem/pollen/services/service/mail/UserAccountCreatedEmail.java b/pollen-services/src/main/java/org/chorem/pollen/services/service/mail/UserAccountCreatedEmail.java index 502b057..373583a 100644 --- a/pollen-services/src/main/java/org/chorem/pollen/services/service/mail/UserAccountCreatedEmail.java +++ b/pollen-services/src/main/java/org/chorem/pollen/services/service/mail/UserAccountCreatedEmail.java @@ -36,7 +36,8 @@ public class UserAccountCreatedEmail extends PollenMail { private PollenUser user; - private String url; + private String validateUrl; + private String pollenUrl; private String password; protected UserAccountCreatedEmail(Locale locale) { @@ -59,12 +60,20 @@ public class UserAccountCreatedEmail extends PollenMail { this.user = user; } - public String getUrl () { - return url; + public String getValidateUrl () { + return validateUrl; } - public void setUrl (String url) { - this.url = url; + public void setValidateUrl (String validateUrl) { + this.validateUrl = validateUrl; + } + + public String getPollenUrl () { + return pollenUrl; + } + + public void setPollenUrl (String pollenUrl) { + this.pollenUrl = pollenUrl; } public String getPassword () { diff --git a/pollen-services/src/main/resources/email/PollCreatedEmail.mustache b/pollen-services/src/main/resources/email/PollCreatedEmail.mustache index fb00542..8b081c7 100644 --- a/pollen-services/src/main/resources/email/PollCreatedEmail.mustache +++ b/pollen-services/src/main/resources/email/PollCreatedEmail.mustache @@ -2,5 +2,14 @@ Hello {{ poll.creator.name }} You had just created the new poll : <a href="{{url}}">{{ poll.title }}</a> +{{#poll.description}} + +------------------------------------- + {{{ poll.description }}} +------------------------------------- + +{{/poll.description}} + +You can now manage your polls by logging on the <a href="{{pollenUrl}}">Pollen</a> website. diff --git a/pollen-services/src/main/resources/email/PollCreatedEmail_fr.mustache b/pollen-services/src/main/resources/email/PollCreatedEmail_fr.mustache index ebc0f1f..1c8fa85 100644 --- a/pollen-services/src/main/resources/email/PollCreatedEmail_fr.mustache +++ b/pollen-services/src/main/resources/email/PollCreatedEmail_fr.mustache @@ -2,4 +2,14 @@ Bonjour {{ poll.creator.name }} Le sondage vient d'être créé : <a href="{{url}}">{{ poll.title }}</a> +{{#poll.description}} + +------------------------------------- + {{{ poll.description }}} + +------------------------------------- + +{{/poll.description}} + +Vous pouvez gérer vos sondage en vous connectant sur <a href="{{pollenUrl}}">Pollen</a>. diff --git a/pollen-services/src/main/resources/email/UserAccountCreatedEmail.mustache b/pollen-services/src/main/resources/email/UserAccountCreatedEmail.mustache index 77981f8..bcd3e20 100644 --- a/pollen-services/src/main/resources/email/UserAccountCreatedEmail.mustache +++ b/pollen-services/src/main/resources/email/UserAccountCreatedEmail.mustache @@ -5,4 +5,6 @@ You had just created an account on the web application Pollen. Email: {{user.email}} Password: {{password}} -You can now manage your polls by logging on the <a href="{{url}}">Pollen</a> website. \ No newline at end of file +You must validate your email on this url : <a href="{{validateUrl}}">{{vaidateUrl}}</a> + +You can now manage your polls by logging on the <a href="{{pollenUrl}}">Pollen</a> website. \ No newline at end of file diff --git a/pollen-services/src/main/resources/email/UserAccountCreatedEmail_fr.mustache b/pollen-services/src/main/resources/email/UserAccountCreatedEmail_fr.mustache index 21f6c9e..09400e2 100644 --- a/pollen-services/src/main/resources/email/UserAccountCreatedEmail_fr.mustache +++ b/pollen-services/src/main/resources/email/UserAccountCreatedEmail_fr.mustache @@ -5,4 +5,6 @@ Vous venez de créer un compte sur l'application en ligne Pollen Courriel: {{user.email}} Password: {{password}} -Vous pouvez gérer vos sondage en vous connectant sur <a href="{{url}}">Pollen</a>. \ No newline at end of file +Vous devez valider votre courriel en allant sur cette adresse : <a href="{{validateUrl}}">{{vaidateUrl}}</a> + +Vous pouvez gérer vos sondage en vous connectant sur <a href="{{pollenUrl}}">Pollen</a>. \ No newline at end of file -- To stop receiving notification emails like this one, please contact chorem.org SCM administrator <admin+scm@chorem.org>.
participants (1)
-
chorem.org scm