Sha256: b764f603342cf47c5ca2857354773b4b6291aa9d12cd5ea3afb80077f029a2bd

Contents?: true

Size: 670 Bytes

Versions: 8

Compression:

Stored size: 670 Bytes

Contents

module Pay
  class UserMailer < Pay.parent_mailer.constantize
    def receipt
      if params[:pay_charge].respond_to? :receipt
        attachments[params[:pay_charge].filename] = params[:pay_charge].receipt
      end

      mail mail_arguments
    end

    def refund
      mail mail_arguments
    end

    def subscription_renewing
      mail mail_arguments
    end

    def payment_action_required
      mail mail_arguments
    end

    def subscription_trial_will_end
      mail mail_arguments
    end

    def subscription_trial_ended
      mail mail_arguments
    end

    private

    def mail_arguments
      instance_exec(&Pay.mail_arguments)
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
pay-6.2.4 app/mailers/pay/user_mailer.rb
pay-6.2.3 app/mailers/pay/user_mailer.rb
pay-6.2.2 app/mailers/pay/user_mailer.rb
pay-6.2.1 app/mailers/pay/user_mailer.rb
pay-6.2.0 app/mailers/pay/user_mailer.rb
pay-6.1.2 app/mailers/pay/user_mailer.rb
pay-6.1.1 app/mailers/pay/user_mailer.rb
pay-6.1.0 app/mailers/pay/user_mailer.rb