2011-06-25 09:38:00 +00:00
|
|
|
class HydrantMailer < ActionMailer::Base
|
|
|
|
default :from => "hello@#{default_url_options[:host]}"
|
|
|
|
|
|
|
|
def reminder_email(hydrant)
|
|
|
|
@hydrant = hydrant
|
|
|
|
@user = hydrant.user
|
2011-06-25 09:53:37 +00:00
|
|
|
mail({
|
2011-06-25 09:38:00 +00:00
|
|
|
:to => hydrant.user.email,
|
|
|
|
:from => "reminder@#{default_url_options[:host]}",
|
|
|
|
:subject => ["Remember to Shovel", hydrant.name].compact.join(' '),
|
2011-06-25 09:53:37 +00:00
|
|
|
})
|
2011-06-25 09:38:00 +00:00
|
|
|
end
|
|
|
|
end
|