class EwayRapid::CreateAccessCodeSharedRequest

Attributes

cancel_url[RW]
checkout_payment[RW]
checkout_url[RW]
custom_view[RW]
customer[RW]
customer_ip[RW]
customer_read_only[RW]
device_id[RW]
header_text[RW]
items[RW]
language[RW]
logo_url[RW]
method[RW]
options[RW]
partner_id[RW]
payment[RW]
redirect_url[RW]
shipping_address[RW]
shipping_method[RW]
transaction_type[RW]
verify_customer_email[RW]
verify_customer_phone[RW]

Public Instance Methods

to_json(opts={}) click to toggle source
# File lib/eway_rapid/entities/create_access_code_shared_request.rb, line 26
def to_json(opts={})
  {
      Constants::CUSTOMER               => InternalModels::Customer.to_hash(customer),
      Constants::SHIPPING_ADDRESS       => InternalModels::ShippingAddress.to_hash(shipping_address),
      Constants::SHIPPING_METHOD        => shipping_method,
      Constants::ITEMS                  => Models::LineItem.to_array(items),
      Constants::OPTIONS                => InternalModels::Option.to_array(options),
      Constants::PAYMENT                => InternalModels::Payment.to_hash(payment),
      Constants::REDIRECT_URL           => redirect_url,
      Constants::CANCEL_URL             => cancel_url,
      Constants::CHECKOUT_URL           => checkout_url,
      Constants::METHOD                 => method,
      Constants::DEVICE_ID              => device_id,
      Constants::CUSTOMER_DEVICE_IP     => customer_ip,
      Constants::TRANSACTION_TYPE       => transaction_type,
      Constants::LOGO_URL               => logo_url,
      Constants::HEADER_TEXT            => header_text,
      Constants::PARTNER_ID             => partner_id,
      Constants::LANGUAGE               => language,
      Constants::CUSTOMER_READ_ONLY     => customer_read_only,
      Constants::CUSTOMER_VIEW          => custom_view,
      Constants::VERIFY_CUSTOMER_PHONE  => verify_customer_phone,
      Constants::VERIFY_CUSTOMER_EMAIL  => verify_customer_email,
      Constants::CHECKOUT_PAYMENT       => checkout_payment
  }.to_json
end