32 lines
879 B
Ruby
32 lines
879 B
Ruby
module JamRuby
|
|
# sends out a boring ale
|
|
class AdminMailer < ActionMailer::Base
|
|
include SendGrid
|
|
|
|
|
|
DEFAULT_SENDER = "JamKazam <noreply@jamkazam.com>"
|
|
|
|
default :from => DEFAULT_SENDER
|
|
|
|
sendgrid_category :use_subject_lines
|
|
#sendgrid_enable :opentrack, :clicktrack # this makes our emails creepy, imo (seth)
|
|
sendgrid_unique_args :env => Environment.mode
|
|
|
|
def alerts(options)
|
|
mail(to: APP_CONFIG.email_alerts_alias,
|
|
from: APP_CONFIG.email_generic_from,
|
|
body: options[:body],
|
|
content_type: "text/plain",
|
|
subject: options[:subject])
|
|
end
|
|
|
|
def recurly_alerts(options)
|
|
mail(to: APP_CONFIG.email_recurly_notice,
|
|
from: APP_CONFIG.email_generic_from,
|
|
body: options[:body],
|
|
content_type: "text/plain",
|
|
subject: options[:subject])
|
|
end
|
|
end
|
|
end
|