Sha256: 162bcd63cb0c2ff855e13d079011d1450cd387065d612786136cb4311b372cfc

Contents?: true

Size: 1005 Bytes

Versions: 4

Compression:

Stored size: 1005 Bytes

Contents

# frozen_string_literal: true

require_relative '../invoice_line/serializer'
require_relative '../reference/serializer'

module LedgerSync
  module Ledgers
    module QuickBooksOnline
      class Invoice
        class Serializer < QuickBooksOnline::Serializer
          id

          date :TxnDate
          attribute :PrivateNote

          references_one 'CurrencyRef',
                         resource_attribute: :Currency,
                         serializer: Reference::Serializer

          references_one 'CustomerRef',
                         resource_attribute: :Customer,
                         serializer: Reference::Serializer

          references_one 'DepositToAccountRef',
                         resource_attribute: :DepositToAccount,
                         serializer: Reference::Serializer

          references_many 'Line',
                          resource_attribute: :Line,
                          serializer: InvoiceLine::Serializer
        end
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
ledger_sync-1.6.0 lib/ledger_sync/ledgers/quickbooks_online/invoice/serializer.rb
ledger_sync-1.5.2 lib/ledger_sync/ledgers/quickbooks_online/invoice/serializer.rb
ledger_sync-1.5.1 lib/ledger_sync/ledgers/quickbooks_online/invoice/serializer.rb
ledger_sync-1.5.0 lib/ledger_sync/ledgers/quickbooks_online/invoice/serializer.rb