Skip to content

Instantly share code, notes, and snippets.

@ahk
Created March 15, 2011 17:54
Show Gist options
  • Save ahk/871136 to your computer and use it in GitHub Desktop.
Save ahk/871136 to your computer and use it in GitHub Desktop.
class ActivityMailer < ActionMailer::Base
def reply(comment, deliver_to_user)
@comment = comment
mail(:subject => I18n.t(:'activity_mailer.subject', :project_name => project.name, :activity_name => response.activity.short_name),
:from => "no-reply@example.com",
:to => deliver_to_user.email)
end
def message(app_message)
@body = app_message.text
mail(:to => app_message.recipient.email,
:subject => "#{app_message.project.name}: #{app_message.subject}",
:from => "no-reply@example.com")
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment