Skip to content

Commit

Permalink
Add Plan URL to feedback notification email.
Browse files Browse the repository at this point in the history
  • Loading branch information
Bodacious authored and briri committed Nov 18, 2022
1 parent 1303a0d commit 5856b86
Showing 1 changed file with 23 additions and 12 deletions.
35 changes: 23 additions & 12 deletions app/views/user_mailer/feedback_notification.html.erb
Original file line number Diff line number Diff line change
@@ -1,17 +1,28 @@
<p>
<%= _('Hello %{user_name},') % {user_name: @recipient_name} %>
</p>
<p>
<%= sanitize _(%Q{%{requestor} has requested feedback on a plan %{link_html}. To add comments, please visit the 'Plans' page under the Admin menu in %{tool_name} and open the plan.}) % {
requestor: @requestor_name,
plan_name: @plan_name,
tool_name: tool_name,
<% FastGettext.with_locale FastGettext.default_locale do %>
<%
recipient_name = @recipient.name(false)
requestor_name = @user.name(false)
plan_name = @plan.title
tool_name = Rails.configuration.branding[:application][:name]
%>

<p><%= _('Hello %{user_name},') % {user_name: recipient_name} %></p>

<p>
<%= raw _(%Q{%{requestor} has requested feedback on a plan %{link_html}. To add comments, please visit the 'Plans' page under the Admin menu in %{application_name} and open the plan.}) % {
requestor: requestor_name,
plan_name: plan_name,
application_name: tool_name,
allow_change_prefs: false,
link_html: link_to(@plan_name, plan_url(@plan))
link_html: link_to(plan_name, plan_url(@plan))
} %>
</p>
</p>

<p>
Alternatively, you can click the link below:<br>
<%= link_to plan_url(@plan), plan_url(@plan) %>
</p>

<p><%= _('Hello %{user_name},') % {user_name: recipient_name} %></p>
<p><%= _('%{requestor} has requested feedback on a plan "%{plan_name}." To add comments, please visit the \'Plans\' page under the Admin menu in %{application_name} and open the plan.') % {requestor: requestor_name, plan_name: plan_name, application_name: tool_name, allow_change_prefs: false} %></p>
<%= render partial: 'email_signature' %>
<% end %>

0 comments on commit 5856b86

Please sign in to comment.