Class: AuthorizeNet::PaymentProfile
- Inherits:
-
DataObject
- Object
- DataObject
- AuthorizeNet::PaymentProfile
- Defined in:
- lib/authorize_net/payment_profile.rb
Constant Summary collapse
- ATTRIBUTES =
{ :id => {:key => "customerPaymentProfileId"}, :credit_card => { :key => "creditCard", :type => AuthorizeNet::DataObject::TYPE_OBJECT, :class => AuthorizeNet::CreditCard, }, :billing_address => { :key => "billTo", :type => AuthorizeNet::DataObject::TYPE_OBJECT, :class => AuthorizeNet::Address, }, }
Constants inherited from DataObject
DataObject::TYPE_ARRAY, DataObject::TYPE_OBJECT, DataObject::TYPE_OBJECT_ARRAY
Instance Method Summary collapse
-
#to_h ⇒ Object
Override.
Methods inherited from DataObject
Instance Method Details
#to_h ⇒ Object
Override
26 27 28 29 30 31 32 33 34 35 36 37 |
# File 'lib/authorize_net/payment_profile.rb', line 26 def to_h hash = super hash.delete('creditCard') if !@credit_card.nil? hash['payment'] = { 'creditCard' => @credit_card.to_h } end return hash end |