Class: ThePlaidApi::SignalPaymentMethod
- Inherits:
-
Object
- Object
- ThePlaidApi::SignalPaymentMethod
- Defined in:
- lib/the_plaid_api/models/signal_payment_method.rb
Overview
The payment method to complete the transaction after the risk assessment. It may be different from the default payment method. ‘SAME_DAY_ACH`: Same Day ACH by Nacha. The debit transaction is processed and settled on the same day. `STANDARD_ACH`: Standard ACH by Nacha. `MULTIPLE_PAYMENT_METHODS`: if there is no default debit rail or there are multiple payment methods.
Constant Summary collapse
- SIGNAL_PAYMENT_METHOD =
[ # TODO: Write general description for SAME_DAY_ACH SAME_DAY_ACH = 'SAME_DAY_ACH'.freeze, # TODO: Write general description for NEXT_DAY_ACH NEXT_DAY_ACH = 'NEXT_DAY_ACH'.freeze, # TODO: Write general description for STANDARD_ACH STANDARD_ACH = 'STANDARD_ACH'.freeze, # TODO: Write general description for MULTIPLE_PAYMENT_METHODS MULTIPLE_PAYMENT_METHODS = 'MULTIPLE_PAYMENT_METHODS'.freeze ].freeze
Class Method Summary collapse
Class Method Details
.from_value(value, default_value = SAME_DAY_ACH) ⇒ Object
33 34 35 36 37 38 39 40 41 42 43 44 45 46 |
# File 'lib/the_plaid_api/models/signal_payment_method.rb', line 33 def self.from_value(value, default_value = SAME_DAY_ACH) return default_value if value.nil? str = value.to_s.strip case str.downcase when 'same_day_ach' then SAME_DAY_ACH when 'next_day_ach' then NEXT_DAY_ACH when 'standard_ach' then STANDARD_ACH when 'multiple_payment_methods' then MULTIPLE_PAYMENT_METHODS else default_value end end |
.validate(value) ⇒ Object
27 28 29 30 31 |
# File 'lib/the_plaid_api/models/signal_payment_method.rb', line 27 def self.validate(value) return false if value.nil? SIGNAL_PAYMENT_METHOD.include?(value) end |