Class: OrderMailer
- Inherits:
-
ActionMailer::Base
- Object
- ActionMailer::Base
- OrderMailer
- Defined in:
- app/mailers/order_mailer.rb
Instance Method Summary collapse
Instance Method Details
#cancel_email(order, resend = false) ⇒ Object
13 14 15 16 17 18 19 20 |
# File 'app/mailers/order_mailer.rb', line 13 def cancel_email(order, resend=false) @order = order subject = (resend ? "[RESEND] " : "") subject += "#{Spree::Config[:site_name]} Cancellation of Order ##{order.number}" mail_params = {:to => order.email, :subject => subject} mail_params[:from] = order.store.email if order.store.email.present? mail(mail_params) end |
#confirm_email(order, resend = false) ⇒ Object
4 5 6 7 8 9 10 11 |
# File 'app/mailers/order_mailer.rb', line 4 def confirm_email(order, resend=false) @order = order subject = (resend ? "[RESEND] " : "") subject += "#{Spree::Config[:site_name]} Order Confirmation ##{order.number}" mail_params = {:to => order.email, :subject => subject} mail_params[:from] = order.store.email if order.store.email.present? mail(mail_params) end |