Class: Spree::MailerPreviews::ReimbursementPreview

Inherits:
ActionMailer::Preview
  • Object
show all
Defined in:
lib/spree/mailer_previews/reimbursement_preview.rb

Instance Method Summary collapse

Instance Method Details

#reimbursementObject



6
7
8
9
10
# File 'lib/spree/mailer_previews/reimbursement_preview.rb', line 6

def reimbursement
  reimbursement = Reimbursement.last
  raise "Your database needs at least one Reimbursement to render this preview" unless reimbursement
  ReimbursementMailer.reimbursement_email(reimbursement)
end