Sha256: ac89550cf67036d3af73a14d18dc479b132f00fa237c542ac7f0c87d23a7d686
Contents?: true
Size: 1004 Bytes
Versions: 4
Compression:
Stored size: 1004 Bytes
Contents
# frozen_string_literal: true require_relative '../reference/serializer' module LedgerSync module Ledgers module QuickBooksOnline class DepositLineDetail class Serializer < QuickBooksOnline::Serializer references_one 'AccountRef', resource_attribute: :Account, serializer: Reference::Serializer references_one 'ClassRef', resource_attribute: :Class, serializer: Reference::Serializer attribute 'Entity' do |args = {}| resource = args.fetch(:resource) if resource.Entity.present? { 'name' => resource.Entity.name, 'value' => resource.Entity.ledger_id, 'type' => Client.ledger_resource_type_for( resource_class: resource.Entity.class ).classify } end end end end end end end
Version data entries
4 entries across 4 versions & 1 rubygems