Newer
Older
dmpopidor / app / views / devise / mailer / invitation_instructions.html.erb
@Gavin Morrice Gavin Morrice on 28 Aug 2018 1 KB Issue 532 (#1847)
<%
  tool_name = Rails.configuration.branding[:application][:name]
  link = accept_invitation_url(@resource, :invitation_token => @token)
  helpdesk_email = Rails.configuration.branding[:organisation][:helpdesk_email]
  contact_us = (Rails.configuration.branding[:organisation][:contact_us_url] || contact_us_url)
  email_subject = _('Query or feedback related to %{tool_name}') %{ :tool_name => tool_name }
%>
<% FastGettext.with_locale FastGettext.default_locale do %>
  <p>
    <%= _('Hello %{user_email}') %{ :user_email => @resource.email } %>
  </p>
  <p>
    <%= _('A colleague has invited you to contribute to their Data Management Plan in %{tool_name}') %{ :tool_name => tool_name } %>
  </p>
  <p>
    <%= sanitize(_('%{click_here} to accept the invitation, (or copy %{link} into your browser). If you don\'t want to accept the invitation, please ignore this email.') % {
      click_here: link_to(_('Click here'), link), link: link
    }) %>
  </p>
  <p>
    <%= _('All the best') %>
    <br />
    <%= _('The %{tool_name} team') %{:tool_name => tool_name} %>
  </p>
  <p>
    <%= _('Please do not reply to this email.') %>&nbsp;
    <%= sanitize(_('If you have any questions or need help, please contact us at %{helpdesk_email} or visit %{contact_us}') % {
      helpdesk_email: mail_to(helpdesk_email, helpdesk_email,
      subject: email_subject),
      contact_us_url: link_to(contact_us, contact_us)
    }) %>
  </p>
<% end %>