Class: Afterpay::Components::Order
- Defined in:
- lib/afterpay/components/order.rb
Instance Attribute Summary collapse
-
#amount ⇒ Afterpay::Components::Money
Total amount for order to be charged to consumer.
-
#billing ⇒ Afterpay::Components::Contact
Billing address.
-
#consumer ⇒ Afterpay::Components::Consumer
The consumer requesting the order.
-
#courier ⇒ Afterpay::Components::Courier
Shipping Courier details.
-
#discounts ⇒ Array<Afterpay::Components::Discount>
An array of discounts.
-
#items ⇒ Array<Afterpay::Components::Item>
An array of order items.
-
#merchant ⇒ Afterpay::Components::Merchant
Merchant’s redirection links..
-
#merchant_reference ⇒ String
The merchant’s id / reference that this order corresponds to.
-
#mode ⇒ String
Set to ‘express` for an express-flow checkout.
-
#payment_type ⇒ String
Supported payment types: ‘PAY_BY_INSTALLMENT’.
-
#shipping ⇒ Afterpay::Components::Contact
Shipping address.
-
#shipping_amount ⇒ Afterpay::Components::Money
The shipping amount.
-
#tax_amount ⇒ Afterpay::Components::Money
The included tax amount after applying all discounts.
Method Summary
Methods included from Initializable
Methods included from Representable
Instance Attribute Details
#amount ⇒ Afterpay::Components::Money
Total amount for order to be charged to consumer.
9 10 11 |
# File 'lib/afterpay/components/order.rb', line 9 def amount @amount end |
#billing ⇒ Afterpay::Components::Contact
Billing address.
19 20 21 |
# File 'lib/afterpay/components/order.rb', line 19 def billing @billing end |
#consumer ⇒ Afterpay::Components::Consumer
The consumer requesting the order.
14 15 16 |
# File 'lib/afterpay/components/order.rb', line 14 def consumer @consumer end |
#courier ⇒ Afterpay::Components::Courier
Shipping Courier details.
29 30 31 |
# File 'lib/afterpay/components/order.rb', line 29 def courier @courier end |
#discounts ⇒ Array<Afterpay::Components::Discount>
An array of discounts.
39 40 41 |
# File 'lib/afterpay/components/order.rb', line 39 def discounts @discounts end |
#items ⇒ Array<Afterpay::Components::Item>
An array of order items.
34 35 36 |
# File 'lib/afterpay/components/order.rb', line 34 def items @items end |
#merchant ⇒ Afterpay::Components::Merchant
Merchant’s redirection links..
44 45 46 |
# File 'lib/afterpay/components/order.rb', line 44 def merchant @merchant end |
#merchant_reference ⇒ String
The merchant’s id / reference that this order corresponds to.
54 55 56 |
# File 'lib/afterpay/components/order.rb', line 54 def merchant_reference @merchant_reference end |
#mode ⇒ String
Set to ‘express` for an express-flow checkout.
69 70 71 |
# File 'lib/afterpay/components/order.rb', line 69 def mode @mode end |
#payment_type ⇒ String
Supported payment types: ‘PAY_BY_INSTALLMENT’. Default is ‘PAY_BY_INSTALLMENT’.
49 50 51 |
# File 'lib/afterpay/components/order.rb', line 49 def payment_type @payment_type end |
#shipping ⇒ Afterpay::Components::Contact
Shipping address.
24 25 26 |
# File 'lib/afterpay/components/order.rb', line 24 def shipping @shipping end |
#shipping_amount ⇒ Afterpay::Components::Money
The shipping amount.
64 65 66 |
# File 'lib/afterpay/components/order.rb', line 64 def shipping_amount @shipping_amount end |
#tax_amount ⇒ Afterpay::Components::Money
The included tax amount after applying all discounts.
59 60 61 |
# File 'lib/afterpay/components/order.rb', line 59 def tax_amount @tax_amount end |