Sha256: 39d62c7930480ca68596edbcb130370547101ca34795bfa9c5be3b45a7ac36af

Contents?: true

Size: 524 Bytes

Versions: 26

Compression:

Stored size: 524 Bytes

Contents

module Spina
  class InquiryMailer < ActionMailer::Base
    layout 'spina/email'

    def inquiry(inquiry)
      @inquiry = inquiry
      @current_account = Account.first

      # attachments.inline['logo.jpg'] = LogoUploader.new.read(@current_account.logo) if @current_account.logo.url

      mail( 
        to: "\"#{@current_account.name}\" <#{ @current_account.email }>", 
        from: "\"#{@inquiry.name}\" <#{@inquiry.email}>",
        subject: @inquiry.message.truncate(97, separator: ' ')
      )
    end

  end
end

Version data entries

26 entries across 26 versions & 1 rubygems

Version Path
spina-0.6.16 app/mailers/spina/inquiry_mailer.rb
spina-0.6.15 app/mailers/spina/inquiry_mailer.rb
spina-0.6.14 app/mailers/spina/inquiry_mailer.rb
spina-0.6.13 app/mailers/spina/inquiry_mailer.rb
spina-0.6.12 app/mailers/spina/inquiry_mailer.rb
spina-0.6.11 app/mailers/spina/inquiry_mailer.rb