Class: LockstepSdk::InvoiceSyncModel

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

Overview

The InvoiceSyncModel represents information coming into Lockstep from an external financial system or other enterprise resource planning system. To import data from an external system, convert your original data into the InvoiceSyncModel format and call the [Upload Sync File API](developer.lockstep.io/reference/post_api-v1-sync-zip). This API retrieves all of the data you uploaded in a compressed ZIP file and imports it into the Lockstep platform.

Once imported, this record will be available in the Lockstep API as an [InvoiceModel](developer.lockstep.io/docs/invoicemodel).

For more information on writing your own connector, see [Connector Data](developer.lockstep.io/docs/connector-data).

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(params = {}) ⇒ InvoiceSyncModel

Initialize the InvoiceSyncModel using the provided prototype



33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 33

def initialize(params = {})
    @erp_key = params.dig(:erp_key)
    @company_erp_key = params.dig(:company_erp_key)
    @customer_erp_key = params.dig(:customer_erp_key)
    @salesperson_name = params.dig(:salesperson_name)
    @purchase_order_code = params.dig(:purchase_order_code)
    @reference_code = params.dig(:reference_code)
    @salesperson_code = params.dig(:salesperson_code)
    @invoice_type_code = params.dig(:invoice_type_code)
    @invoice_status_code = params.dig(:invoice_status_code)
    @terms_code = params.dig(:terms_code)
    @special_terms = params.dig(:special_terms)
    @currency_code = params.dig(:currency_code)
    @total_amount = params.dig(:total_amount)
    @sales_tax_amount = params.dig(:sales_tax_amount)
    @discount_amount = params.dig(:discount_amount)
    @outstanding_balance_amount = params.dig(:outstanding_balance_amount)
    @invoice_date = params.dig(:invoice_date)
    @discount_date = params.dig(:discount_date)
    @posted_date = params.dig(:posted_date)
    @invoice_closed_date = params.dig(:invoice_closed_date)
    @payment_due_date = params.dig(:payment_due_date)
    @imported_date = params.dig(:imported_date)
    @origin_address_line1 = params.dig(:origin_address_line1)
    @origin_address_line2 = params.dig(:origin_address_line2)
    @origin_address_line3 = params.dig(:origin_address_line3)
    @origin_address_city = params.dig(:origin_address_city)
    @origin_address_region = params.dig(:origin_address_region)
    @origin_address_postal_code = params.dig(:origin_address_postal_code)
    @origin_address_country = params.dig(:origin_address_country)
    @origin_address_latitude = params.dig(:origin_address_latitude)
    @origin_address_longitude = params.dig(:origin_address_longitude)
    @bill_to_address_line1 = params.dig(:bill_to_address_line1)
    @bill_to_address_line2 = params.dig(:bill_to_address_line2)
    @bill_to_address_line3 = params.dig(:bill_to_address_line3)
    @bill_to_address_city = params.dig(:bill_to_address_city)
    @bill_to_address_region = params.dig(:bill_to_address_region)
    @bill_to_address_postal_code = params.dig(:bill_to_address_postal_code)
    @bill_to_address_country = params.dig(:bill_to_address_country)
    @bill_to_address_latitude = params.dig(:bill_to_address_latitude)
    @bill_to_address_longitude = params.dig(:bill_to_address_longitude)
    @ship_to_address_line1 = params.dig(:ship_to_address_line1)
    @ship_to_address_line2 = params.dig(:ship_to_address_line2)
    @ship_to_address_line3 = params.dig(:ship_to_address_line3)
    @ship_to_address_city = params.dig(:ship_to_address_city)
    @ship_to_address_region = params.dig(:ship_to_address_region)
    @ship_to_address_postal_code = params.dig(:ship_to_address_postal_code)
    @ship_to_address_country = params.dig(:ship_to_address_country)
    @ship_to_address_latitude = params.dig(:ship_to_address_latitude)
    @ship_to_address_longitude = params.dig(:ship_to_address_longitude)
    @created = params.dig(:created)
    @modified = params.dig(:modified)
    @is_voided = params.dig(:is_voided)
    @in_dispute = params.dig(:in_dispute)
    @preferred_delivery_method = params.dig(:preferred_delivery_method)
end

Instance Attribute Details

#bill_to_address_cityString

Returns The billing address for this invoice.

Returns:

  • (String)

    The billing address for this invoice



228
229
230
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 228

def bill_to_address_city
  @bill_to_address_city
end

#bill_to_address_countryString

Returns The billing address for this invoice.

Returns:

  • (String)

    The billing address for this invoice



240
241
242
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 240

def bill_to_address_country
  @bill_to_address_country
end

#bill_to_address_latitudeFloat

Returns The billing address for this invoice.

Returns:

  • (Float)

    The billing address for this invoice



244
245
246
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 244

def bill_to_address_latitude
  @bill_to_address_latitude
end

#bill_to_address_line1String

Returns The billing address for this invoice.

Returns:

  • (String)

    The billing address for this invoice



216
217
218
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 216

def bill_to_address_line1
  @bill_to_address_line1
end

#bill_to_address_line2String

Returns The billing address for this invoice.

Returns:

  • (String)

    The billing address for this invoice



220
221
222
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 220

def bill_to_address_line2
  @bill_to_address_line2
end

#bill_to_address_line3String

Returns The billing address for this invoice.

Returns:

  • (String)

    The billing address for this invoice



224
225
226
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 224

def bill_to_address_line3
  @bill_to_address_line3
end

#bill_to_address_longitudeFloat

Returns The billing address for this invoice.

Returns:

  • (Float)

    The billing address for this invoice



248
249
250
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 248

def bill_to_address_longitude
  @bill_to_address_longitude
end

#bill_to_address_postal_codeString

Returns The billing address for this invoice.

Returns:

  • (String)

    The billing address for this invoice



236
237
238
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 236

def bill_to_address_postal_code
  @bill_to_address_postal_code
end

#bill_to_address_regionString

Returns The billing address for this invoice.

Returns:

  • (String)

    The billing address for this invoice



232
233
234
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 232

def bill_to_address_region
  @bill_to_address_region
end

#company_erp_keyString

Returns The original primary key or unique ID of the company to which this invoice belongs. This value should match the [Company ErpKey](developer.lockstep.io/docs/importing-companies#erpkey) field on the [CompanySyncModel](developer.lockstep.io/docs/importing-companies). An Invoice has two relationships: The Company and the Customer. The field CompanyErpKey identifies the company that created the invoice, and the field CustomerErpKey is the customer to whom the invoice was sent.

Returns:



96
97
98
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 96

def company_erp_key
  @company_erp_key
end

#createdDate-time

Returns If known, the date when this record was created according to the originating financial system in which this record is maintained. If the originating financial system does not maintain a created-date, leave this field null.

Returns:

  • (Date-time)

    If known, the date when this record was created according to the originating financial system in which this record is maintained. If the originating financial system does not maintain a created-date, leave this field null.



288
289
290
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 288

def created
  @created
end

#currency_codeString

Returns The three-character ISO 4217 currency code used for this invoice. This will be validated by the /api/v1/definitions/currencies data set.

Returns:

  • (String)

    The three-character ISO 4217 currency code used for this invoice. This will be validated by the /api/v1/definitions/currencies data set



136
137
138
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 136

def currency_code
  @currency_code
end

#customer_erp_keyString

Returns The original primary key or unique ID of the company to which this invoice was sent. This value should match the [Company ErpKey](developer.lockstep.io/docs/importing-companies#erpkey) field on the [CompanySyncModel](developer.lockstep.io/docs/importing-companies). An Invoice has two relationships: The Company and the Customer. The field CompanyErpKey identifies the company that created the invoice, and the field CustomerErpKey is the customer to whom the invoice was sent.

Returns:



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

def customer_erp_key
  @customer_erp_key
end

#discount_amountDouble

Returns The total discounts given by the seller to the buyer on this invoice.

Returns:

  • (Double)

    The total discounts given by the seller to the buyer on this invoice.



148
149
150
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 148

def discount_amount
  @discount_amount
end

#discount_dateDate-time

Returns The date when discounts were adjusted for this invoice.

Returns:

  • (Date-time)

    The date when discounts were adjusted for this invoice.



160
161
162
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 160

def discount_date
  @discount_date
end

#erp_keyString

Returns This is the primary key of the Invoice record. For this field, you should use whatever the invoice’s unique identifying number is in the originating system. Search for a unique, non-changing number within the originating financial system for this record. Example: If you store your invoice records in a database, whatever the primary key for the invoice table is in the database should be the “ErpKey”. For more information, see [Identity Columns](developer.lockstep.io/docs/identity-columns).

Returns:

  • (String)

    This is the primary key of the Invoice record. For this field, you should use whatever the invoice’s unique identifying number is in the originating system. Search for a unique, non-changing number within the originating financial system for this record. Example: If you store your invoice records in a database, whatever the primary key for the invoice table is in the database should be the “ErpKey”. For more information, see [Identity Columns](developer.lockstep.io/docs/identity-columns).



92
93
94
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 92

def erp_key
  @erp_key
end

#imported_dateDate-time

Returns The date and time when this record was imported from the user’s ERP or accounting system.

Returns:

  • (Date-time)

    The date and time when this record was imported from the user’s ERP or accounting system.



176
177
178
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 176

def imported_date
  @imported_date
end

#in_disputeBoolean

Returns Is the invoice in dispute? If not specified, we assume the invoice is not in dispute.

Returns:

  • (Boolean)

    Is the invoice in dispute? If not specified, we assume the invoice is not in dispute.



300
301
302
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 300

def in_dispute
  @in_dispute
end

#invoice_closed_dateDate-time

Returns The date when the invoice was closed and finalized after completion of all payments and delivery of all products and services.

Returns:

  • (Date-time)

    The date when the invoice was closed and finalized after completion of all payments and delivery of all products and services.



168
169
170
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 168

def invoice_closed_date
  @invoice_closed_date
end

#invoice_dateDate-time

Returns The reporting date for this invoice.

Returns:

  • (Date-time)

    The reporting date for this invoice.



156
157
158
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 156

def invoice_date
  @invoice_date
end

#invoice_status_codeString

Returns A code identifying the status of this invoice. Recognized Invoice status codes are: * Open - Represents an invoice that is considered open and needs more work to complete * Closed - Represents an invoice that is considered closed and resolved.

Returns:

  • (String)

    A code identifying the status of this invoice. Recognized Invoice status codes are: * Open - Represents an invoice that is considered open and needs more work to complete * Closed - Represents an invoice that is considered closed and resolved



124
125
126
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 124

def invoice_status_code
  @invoice_status_code
end

#invoice_type_codeString

Returns A code identifying the type of this invoice. Recognized Invoice types are: * ‘AR Invoice` - Represents an invoice sent by Company to the Customer * `AP Invoice` - Represents an invoice sent by Vendor to the Company * `AR Credit Memo` - Represents a credit memo generated by Company given to Customer * `AP Credit Memo` - Represents a credit memo generated by Vendor given to Company.

Returns:

  • (String)

    A code identifying the type of this invoice. Recognized Invoice types are: * ‘AR Invoice` - Represents an invoice sent by Company to the Customer * `AP Invoice` - Represents an invoice sent by Vendor to the Company * `AR Credit Memo` - Represents a credit memo generated by Company given to Customer * `AP Credit Memo` - Represents a credit memo generated by Vendor given to Company



120
121
122
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 120

def invoice_type_code
  @invoice_type_code
end

#is_voidedBoolean

Returns Is the invoice voided? If not specified, we assume the invoice is not voided.

Returns:

  • (Boolean)

    Is the invoice voided? If not specified, we assume the invoice is not voided.



296
297
298
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 296

def is_voided
  @is_voided
end

#modifiedDate-time

Returns If known, the date when this record was most recently modified according to the originating financial system in which this record is maintained. If the originating financial system does not maintain a most-recently-modified-date, leave this field null.

Returns:

  • (Date-time)

    If known, the date when this record was most recently modified according to the originating financial system in which this record is maintained. If the originating financial system does not maintain a most-recently-modified-date, leave this field null.



292
293
294
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 292

def modified
  @modified
end

#origin_address_cityString

Returns The origination address for this invoice.

Returns:

  • (String)

    The origination address for this invoice



192
193
194
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 192

def origin_address_city
  @origin_address_city
end

#origin_address_countryString

Returns The origination address for this invoice.

Returns:

  • (String)

    The origination address for this invoice



204
205
206
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 204

def origin_address_country
  @origin_address_country
end

#origin_address_latitudeFloat

Returns The origination address for this invoice.

Returns:

  • (Float)

    The origination address for this invoice



208
209
210
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 208

def origin_address_latitude
  @origin_address_latitude
end

#origin_address_line1String

Returns The origination address for this invoice.

Returns:

  • (String)

    The origination address for this invoice



180
181
182
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 180

def origin_address_line1
  @origin_address_line1
end

#origin_address_line2String

Returns The origination address for this invoice.

Returns:

  • (String)

    The origination address for this invoice



184
185
186
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 184

def origin_address_line2
  @origin_address_line2
end

#origin_address_line3String

Returns The origination address for this invoice.

Returns:

  • (String)

    The origination address for this invoice



188
189
190
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 188

def origin_address_line3
  @origin_address_line3
end

#origin_address_longitudeFloat

Returns The origination address for this invoice.

Returns:

  • (Float)

    The origination address for this invoice



212
213
214
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 212

def origin_address_longitude
  @origin_address_longitude
end

#origin_address_postal_codeString

Returns The origination address for this invoice.

Returns:

  • (String)

    The origination address for this invoice



200
201
202
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 200

def origin_address_postal_code
  @origin_address_postal_code
end

#origin_address_regionString

Returns The origination address for this invoice.

Returns:

  • (String)

    The origination address for this invoice



196
197
198
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 196

def origin_address_region
  @origin_address_region
end

#outstanding_balance_amountDouble

Returns The remaining balance value of this invoice.

Returns:

  • (Double)

    The remaining balance value of this invoice.



152
153
154
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 152

def outstanding_balance_amount
  @outstanding_balance_amount
end

#payment_due_dateDate-time

Returns The date when the remaining outstanding balance is due.

Returns:

  • (Date-time)

    The date when the remaining outstanding balance is due.



172
173
174
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 172

def payment_due_date
  @payment_due_date
end

#posted_dateDate-time

Returns The date when this invoice posted to the company’s general ledger.

Returns:

  • (Date-time)

    The date when this invoice posted to the company’s general ledger.



164
165
166
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 164

def posted_date
  @posted_date
end

#preferred_delivery_methodString

Returns Indicates the preferred delivery method for this invoice. Examples include Print, Email, Fax.

Returns:

  • (String)

    Indicates the preferred delivery method for this invoice. Examples include Print, Email, Fax



304
305
306
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 304

def preferred_delivery_method
  @preferred_delivery_method
end

#purchase_order_codeString

Returns The “Purchase Order Code” is a code that is sometimes used by companies to refer to the original PO that was sent that caused this invoice to be written. If a customer sends a purchase order to a vendor, the vendor can then create an invoice and refer back to the originating purchase order using this field.

Returns:

  • (String)

    The “Purchase Order Code” is a code that is sometimes used by companies to refer to the original PO that was sent that caused this invoice to be written. If a customer sends a purchase order to a vendor, the vendor can then create an invoice and refer back to the originating purchase order using this field.



108
109
110
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 108

def purchase_order_code
  @purchase_order_code
end

#reference_codeString

Returns An additional reference code that is sometimes used to identify this invoice. The meaning of this field is specific to the ERP or accounting system used by the user.

Returns:

  • (String)

    An additional reference code that is sometimes used to identify this invoice. The meaning of this field is specific to the ERP or accounting system used by the user.



112
113
114
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 112

def reference_code
  @reference_code
end

#sales_tax_amountDouble

Returns The total sales (or transactional) tax calculated for this invoice.

Returns:

  • (Double)

    The total sales (or transactional) tax calculated for this invoice.



144
145
146
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 144

def sales_tax_amount
  @sales_tax_amount
end

#salesperson_codeString

Returns A code identifying the salesperson responsible for writing this quote, invoice, or order. This is just text, it is not a reference to the “Contacts” table. You will not receive an error if this field does not match a known contact person.

Returns:

  • (String)

    A code identifying the salesperson responsible for writing this quote, invoice, or order. This is just text, it is not a reference to the “Contacts” table. You will not receive an error if this field does not match a known contact person.



116
117
118
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 116

def salesperson_code
  @salesperson_code
end

#salesperson_nameString

Returns The name of the salesperson that wrote this invoice. This is just text, it is not a reference to the “Contacts” table. You will not receive an error if this field does not match a known contact person.

Returns:

  • (String)

    The name of the salesperson that wrote this invoice. This is just text, it is not a reference to the “Contacts” table. You will not receive an error if this field does not match a known contact person.



104
105
106
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 104

def salesperson_name
  @salesperson_name
end

#ship_to_address_cityString

Returns The shipping address for this invoice.

Returns:

  • (String)

    The shipping address for this invoice



264
265
266
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 264

def ship_to_address_city
  @ship_to_address_city
end

#ship_to_address_countryString

Returns The shipping address for this invoice.

Returns:

  • (String)

    The shipping address for this invoice



276
277
278
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 276

def ship_to_address_country
  @ship_to_address_country
end

#ship_to_address_latitudeFloat

Returns The shipping address for this invoice.

Returns:

  • (Float)

    The shipping address for this invoice



280
281
282
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 280

def ship_to_address_latitude
  @ship_to_address_latitude
end

#ship_to_address_line1String

Returns The shipping address for this invoice.

Returns:

  • (String)

    The shipping address for this invoice



252
253
254
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 252

def ship_to_address_line1
  @ship_to_address_line1
end

#ship_to_address_line2String

Returns The shipping address for this invoice.

Returns:

  • (String)

    The shipping address for this invoice



256
257
258
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 256

def ship_to_address_line2
  @ship_to_address_line2
end

#ship_to_address_line3String

Returns The shipping address for this invoice.

Returns:

  • (String)

    The shipping address for this invoice



260
261
262
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 260

def ship_to_address_line3
  @ship_to_address_line3
end

#ship_to_address_longitudeFloat

Returns The shipping address for this invoice.

Returns:

  • (Float)

    The shipping address for this invoice



284
285
286
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 284

def ship_to_address_longitude
  @ship_to_address_longitude
end

#ship_to_address_postal_codeString

Returns The shipping address for this invoice.

Returns:

  • (String)

    The shipping address for this invoice



272
273
274
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 272

def ship_to_address_postal_code
  @ship_to_address_postal_code
end

#ship_to_address_regionString

Returns The shipping address for this invoice.

Returns:

  • (String)

    The shipping address for this invoice



268
269
270
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 268

def ship_to_address_region
  @ship_to_address_region
end

#special_termsString

Returns If the customer negotiated any special terms different from the standard terms above, describe them here.

Returns:

  • (String)

    If the customer negotiated any special terms different from the standard terms above, describe them here.



132
133
134
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 132

def special_terms
  @special_terms
end

#terms_codeString

Returns A code identifying the terms given to the purchaser. This field is imported directly from the originating financial system and does not follow a specified format.

Returns:

  • (String)

    A code identifying the terms given to the purchaser. This field is imported directly from the originating financial system and does not follow a specified format.



128
129
130
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 128

def terms_code
  @terms_code
end

#total_amountDouble

Returns The total value of this invoice, inclusive of all taxes and line items.

Returns:

  • (Double)

    The total value of this invoice, inclusive of all taxes and line items.



140
141
142
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 140

def total_amount
  @total_amount
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



308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 308

def as_json(options={})
    {
        'erpKey' => @erp_key,
        'companyErpKey' => @company_erp_key,
        'customerErpKey' => @customer_erp_key,
        'salespersonName' => @salesperson_name,
        'purchaseOrderCode' => @purchase_order_code,
        'referenceCode' => @reference_code,
        'salespersonCode' => @salesperson_code,
        'invoiceTypeCode' => @invoice_type_code,
        'invoiceStatusCode' => @invoice_status_code,
        'termsCode' => @terms_code,
        'specialTerms' => @special_terms,
        'currencyCode' => @currency_code,
        'totalAmount' => @total_amount,
        'salesTaxAmount' => @sales_tax_amount,
        'discountAmount' => @discount_amount,
        'outstandingBalanceAmount' => @outstanding_balance_amount,
        'invoiceDate' => @invoice_date,
        'discountDate' => @discount_date,
        'postedDate' => @posted_date,
        'invoiceClosedDate' => @invoice_closed_date,
        'paymentDueDate' => @payment_due_date,
        'importedDate' => @imported_date,
        'originAddressLine1' => @origin_address_line1,
        'originAddressLine2' => @origin_address_line2,
        'originAddressLine3' => @origin_address_line3,
        'originAddressCity' => @origin_address_city,
        'originAddressRegion' => @origin_address_region,
        'originAddressPostalCode' => @origin_address_postal_code,
        'originAddressCountry' => @origin_address_country,
        'originAddressLatitude' => @origin_address_latitude,
        'originAddressLongitude' => @origin_address_longitude,
        'billToAddressLine1' => @bill_to_address_line1,
        'billToAddressLine2' => @bill_to_address_line2,
        'billToAddressLine3' => @bill_to_address_line3,
        'billToAddressCity' => @bill_to_address_city,
        'billToAddressRegion' => @bill_to_address_region,
        'billToAddressPostalCode' => @bill_to_address_postal_code,
        'billToAddressCountry' => @bill_to_address_country,
        'billToAddressLatitude' => @bill_to_address_latitude,
        'billToAddressLongitude' => @bill_to_address_longitude,
        'shipToAddressLine1' => @ship_to_address_line1,
        'shipToAddressLine2' => @ship_to_address_line2,
        'shipToAddressLine3' => @ship_to_address_line3,
        'shipToAddressCity' => @ship_to_address_city,
        'shipToAddressRegion' => @ship_to_address_region,
        'shipToAddressPostalCode' => @ship_to_address_postal_code,
        'shipToAddressCountry' => @ship_to_address_country,
        'shipToAddressLatitude' => @ship_to_address_latitude,
        'shipToAddressLongitude' => @ship_to_address_longitude,
        'created' => @created,
        'modified' => @modified,
        'isVoided' => @is_voided,
        'inDispute' => @in_dispute,
        'preferredDeliveryMethod' => @preferred_delivery_method,
    }
end

#to_json(*options) ⇒ String

Returns This object converted to a JSON string.

Returns:

  • (String)

    This object converted to a JSON string



369
370
371
# File 'lib/lockstep_sdk/models/invoice_sync_model.rb', line 369

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