Sha256: 1607d0474360bc4632c49268a2ee18946ab526e8d7066ce46cb0eb32652cc7a1

Contents?: true

Size: 564 Bytes

Versions: 3

Compression:

Stored size: 564 Bytes

Contents

require "economic/proxies/entity_proxy"

module Economic
  class CurrentInvoiceLineProxy < EntityProxy
    # Gets data for CurrentInvoiceLine from the API
    def find(handle)
      handle = Entity::Handle.build(:number => handle) unless handle.is_a?(Entity::Handle)
      super(handle)
    end

    private

    # Initialize properties in invoice_line with values from owner
    def initialize_properties_with_values_from_owner(invoice_line)
      if owner.is_a?(CurrentInvoice)
        invoice_line.invoice = owner
      end
      invoice_line
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
rconomic-0.7.0 lib/economic/proxies/current_invoice_line_proxy.rb
rconomic-0.6.1 lib/economic/proxies/current_invoice_line_proxy.rb
rconomic-0.6.0 lib/economic/proxies/current_invoice_line_proxy.rb