Class: Mundipagg::Boleto
- Inherits:
-
ActiveMerchant::Billing::Model
- Object
- ActiveMerchant::Billing::Model
- Mundipagg::Boleto
- Defined in:
- lib/mundipagg/boleto.rb
Defined Under Namespace
Classes: Response
Instance Attribute Summary collapse
-
#bank_code ⇒ Object
Returns the value of attribute bank_code.
-
#bank_number ⇒ Object
Returns the value of attribute bank_number.
-
#days_to_expire ⇒ Object
Returns the value of attribute days_to_expire.
-
#instructions ⇒ Object
Returns the value of attribute instructions.
Instance Method Summary collapse
Instance Attribute Details
#bank_code ⇒ Object
Returns the value of attribute bank_code.
3 4 5 |
# File 'lib/mundipagg/boleto.rb', line 3 def bank_code @bank_code end |
#bank_number ⇒ Object
Returns the value of attribute bank_number.
3 4 5 |
# File 'lib/mundipagg/boleto.rb', line 3 def bank_number @bank_number end |
#days_to_expire ⇒ Object
Returns the value of attribute days_to_expire.
3 4 5 |
# File 'lib/mundipagg/boleto.rb', line 3 def days_to_expire @days_to_expire end |
#instructions ⇒ Object
Returns the value of attribute instructions.
3 4 5 |
# File 'lib/mundipagg/boleto.rb', line 3 def instructions @instructions end |
Instance Method Details
#payload(amount) ⇒ Object
5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 |
# File 'lib/mundipagg/boleto.rb', line 5 def payload(amount) content = { amount_in_cents: amount, bank_number: bank_number, days_to_add_in_boleto_expiration_date: days_to_expire || 5, instructions: instructions, nosso_numero: bank_code } { amount_in_cents: amount, currency_iso_enum: "BRL", boleto_transaction_collection: { boleto_transaction: content } } end |