From ce4a6eefa7405a3d23f722c987f0e22b966defc8 Mon Sep 17 00:00:00 2001 From: Tom Hughes Date: Thu, 1 Dec 2011 19:17:16 +0000 Subject: [PATCH] Add an HTML version of the message notification email --- app/models/notifier.rb | 1 + app/views/notifier/message_notification.html.erb | 12 ++++++++++++ 2 files changed, 13 insertions(+) create mode 100644 app/views/notifier/message_notification.html.erb diff --git a/app/models/notifier.rb b/app/models/notifier.rb index 2b6574a97..1223d54b1 100644 --- a/app/models/notifier.rb +++ b/app/models/notifier.rb @@ -2,6 +2,7 @@ class Notifier < ActionMailer::Base default :from => EMAIL_FROM, :return_path => EMAIL_RETURN_PATH, :auto_submitted => "auto-generated" + helper :application def signup_confirm(user, token) @locale = user.preferred_language_from(I18n.available_locales) diff --git a/app/views/notifier/message_notification.html.erb b/app/views/notifier/message_notification.html.erb new file mode 100644 index 000000000..ef55b9b96 --- /dev/null +++ b/app/views/notifier/message_notification.html.erb @@ -0,0 +1,12 @@ +

<%= t'notifier.message_notification.hi', :to_user => @to_user %>

+ +

<%= raw t'notifier.message_notification.header', :from_user => link_to(@from_user, :host => SERVER_URL, :controller => :user, :action => :view, :display_name => @from_user), :subject => @title %>

+ +== +<%= htmlize @text %> +== + +

+ <%= raw t'notifier.message_notification.footer1', :readurl => link_to(@readurl, @readurl) %> + <%= raw t'notifier.message_notification.footer2', :replyurl => link_to(@replyurl, @replyurl) %> +

-- 2.43.2