Class: LockstepSdk::CustomerDetailsPaymentModel

Inherits:
Object
  • Object
show all
Defined in:
lib/lockstep_sdk/models/customer_details_payment_model.rb

Overview

Customer payment collected information

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(params = {}) ⇒ CustomerDetailsPaymentModel

Initialize the CustomerDetailsPaymentModel using the provided prototype



28
29
30
31
32
33
34
35
36
37
38
39
# File 'lib/lockstep_sdk/models/customer_details_payment_model.rb', line 28

def initialize(params = {})
    @group_key = params.dig(:group_key)
    @payment_id = params.dig(:payment_id)
    @payment_applied_id = params.dig(:payment_applied_id)
    @payment_type = params.dig(:payment_type)
    @invoice_id = params.dig(:invoice_id)
    @invoice_type_code = params.dig(:invoice_type_code)
    @invoice_reference_code = params.dig(:invoice_reference_code)
    @invoice_total_amount = params.dig(:invoice_total_amount)
    @payment_date = params.dig(:payment_date)
    @payment_amount = params.dig(:payment_amount)
end

Instance Attribute Details

#group_keyUuid

Returns The GroupKey uniquely identifies a single Lockstep Platform account. All records for this account will share the same GroupKey value. GroupKey values cannot be changed once created. For more information, see [Accounts and GroupKeys](developer.lockstep.io/docs/accounts-and-groupkeys).

Returns:

  • (Uuid)

    The GroupKey uniquely identifies a single Lockstep Platform account. All records for this account will share the same GroupKey value. GroupKey values cannot be changed once created. For more information, see [Accounts and GroupKeys](developer.lockstep.io/docs/accounts-and-groupkeys).



43
44
45
# File 'lib/lockstep_sdk/models/customer_details_payment_model.rb', line 43

def group_key
  @group_key
end

#invoice_idUuid

Returns Unique identifier for invoice payment is associated with.

Returns:

  • (Uuid)

    Unique identifier for invoice payment is associated with



59
60
61
# File 'lib/lockstep_sdk/models/customer_details_payment_model.rb', line 59

def invoice_id
  @invoice_id
end

#invoice_reference_codeString

Returns Invoice reference code payment is associated with.

Returns:

  • (String)

    Invoice reference code payment is associated with



67
68
69
# File 'lib/lockstep_sdk/models/customer_details_payment_model.rb', line 67

def invoice_reference_code
  @invoice_reference_code
end

#invoice_total_amountDouble

Returns Invoice total amount payment is associated with.

Returns:

  • (Double)

    Invoice total amount payment is associated with



71
72
73
# File 'lib/lockstep_sdk/models/customer_details_payment_model.rb', line 71

def invoice_total_amount
  @invoice_total_amount
end

#invoice_type_codeString

Returns Invoice type payment is associated with.

Returns:

  • (String)

    Invoice type payment is associated with



63
64
65
# File 'lib/lockstep_sdk/models/customer_details_payment_model.rb', line 63

def invoice_type_code
  @invoice_type_code
end

#payment_amountDouble

Returns Amount payment was made for.

Returns:

  • (Double)

    Amount payment was made for



79
80
81
# File 'lib/lockstep_sdk/models/customer_details_payment_model.rb', line 79

def payment_amount
  @payment_amount
end

#payment_applied_idUuid

Returns Unique identifier for payment applied.

Returns:

  • (Uuid)

    Unique identifier for payment applied



51
52
53
# File 'lib/lockstep_sdk/models/customer_details_payment_model.rb', line 51

def payment_applied_id
  @payment_applied_id
end

#payment_dateDate-time

Returns Date payment placed.

Returns:

  • (Date-time)

    Date payment placed



75
76
77
# File 'lib/lockstep_sdk/models/customer_details_payment_model.rb', line 75

def payment_date
  @payment_date
end

#payment_idUuid

Returns Unique identifier for payment.

Returns:

  • (Uuid)

    Unique identifier for payment



47
48
49
# File 'lib/lockstep_sdk/models/customer_details_payment_model.rb', line 47

def payment_id
  @payment_id
end

#payment_typeString

Returns Payment type.

Returns:

  • (String)

    Payment type



55
56
57
# File 'lib/lockstep_sdk/models/customer_details_payment_model.rb', line 55

def payment_type
  @payment_type
end

Instance Method Details

#as_json(options = {}) ⇒ object

Returns This object as a JSON key-value structure.

Returns:

  • (object)

    This object as a JSON key-value structure



83
84
85
86
87
88
89
90
91
92
93
94
95
96
# File 'lib/lockstep_sdk/models/customer_details_payment_model.rb', line 83

def as_json(options={})
    {
        'groupKey' => @group_key,
        'paymentId' => @payment_id,
        'paymentAppliedId' => @payment_applied_id,
        'paymentType' => @payment_type,
        'invoiceId' => @invoice_id,
        'invoiceTypeCode' => @invoice_type_code,
        'invoiceReferenceCode' => @invoice_reference_code,
        'invoiceTotalAmount' => @invoice_total_amount,
        'paymentDate' => @payment_date,
        'paymentAmount' => @payment_amount,
    }
end

#to_json(*options) ⇒ String

Returns This object converted to a JSON string.

Returns:

  • (String)

    This object converted to a JSON string



100
101
102
# File 'lib/lockstep_sdk/models/customer_details_payment_model.rb', line 100

def to_json(*options)
    "[#{as_json(*options).to_json(*options)}]"
end