2014-06-23 23:39:42 +02:00
|
|
|
class NoteMailer < ActionMailer::Base
|
2014-07-21 01:26:58 +02:00
|
|
|
def notify(note)
|
2014-06-23 23:39:42 +02:00
|
|
|
@note = note
|
|
|
|
|
2014-06-29 13:37:08 +02:00
|
|
|
mail 'In-Reply-To' => "<event-#{note.event.id}@#{ActionMailer::Base.default_url_options[:host]}>",
|
2014-07-20 23:33:05 +02:00
|
|
|
to: note.event.submitter,
|
2014-07-21 01:26:58 +02:00
|
|
|
subject: t('note_mailer.notify.subject', subject: note.event.title)
|
|
|
|
end
|
|
|
|
|
|
|
|
def create(note)
|
|
|
|
@note = note
|
|
|
|
|
|
|
|
mail 'In-Reply-To' => "<mod-#{note.event.id}@#{ActionMailer::Base.default_url_options[:host]}>",
|
2014-06-29 13:37:08 +02:00
|
|
|
subject: t('note_mailer.create.subject', subject: note.event.title)
|
2014-06-23 23:39:42 +02:00
|
|
|
end
|
|
|
|
end
|