Class: KintsugiSDK::Models::Shared::TransactionEstimateResponse

Inherits:
Object
  • Object
show all
Extended by:
T::Sig
Includes:
Crystalline::MetadataFields
Defined in:
lib/kintsugi_sdk/models/shared/transactionestimateresponse.rb

Instance Method Summary collapse

Methods included from Crystalline::MetadataFields

#field, #fields, included, #marshal_single, #to_dict, #to_json

Constructor Details

#initialize(date:, external_id:, currency:, transaction_items:, addresses:, description: nil, source: nil, customer: nil, total_amount: '0.0', marketplace: false, total_tax_amount_calculated: '0.00', taxable_amount: '0.00', tax_rate_calculated: '0.00', nexus_met: false, has_active_registration: false) ⇒ TransactionEstimateResponse

Returns a new instance of TransactionEstimateResponse.



50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
# File 'lib/kintsugi_sdk/models/shared/transactionestimateresponse.rb', line 50

def initialize(date:, external_id:, currency:, transaction_items:, addresses:, description: nil, source: nil, customer: nil, total_amount: '0.0', marketplace: false, total_tax_amount_calculated: '0.00', taxable_amount: '0.00', tax_rate_calculated: '0.00', nexus_met: false, has_active_registration: false)
  @date = date
  @external_id = external_id
  @currency = currency
  @transaction_items = transaction_items
  @addresses = addresses
  @description = description
  @source = source
  @customer = customer
  @total_amount = total_amount
  @marketplace = marketplace
  @total_tax_amount_calculated = total_tax_amount_calculated
  @taxable_amount = taxable_amount
  @tax_rate_calculated = tax_rate_calculated
  @nexus_met = nexus_met
  @has_active_registration = has_active_registration
end

Instance Method Details

#==(other) ⇒ Object



69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
# File 'lib/kintsugi_sdk/models/shared/transactionestimateresponse.rb', line 69

def ==(other)
  return false unless other.is_a? self.class
  return false unless @date == other.date
  return false unless @external_id == other.external_id
  return false unless @currency == other.currency
  return false unless @transaction_items == other.transaction_items
  return false unless @addresses == other.addresses
  return false unless @description == other.description
  return false unless @source == other.source
  return false unless @customer == other.customer
  return false unless @total_amount == other.total_amount
  return false unless @marketplace == other.marketplace
  return false unless @total_tax_amount_calculated == other.total_tax_amount_calculated
  return false unless @taxable_amount == other.taxable_amount
  return false unless @tax_rate_calculated == other.tax_rate_calculated
  return false unless @nexus_met == other.nexus_met
  return false unless @has_active_registration == other.has_active_registration
  true
end