class Economic::OrderLine
Public Instance Methods
handle()
click to toggle source
# File lib/economic/order_line.rb, line 24 def handle @handle || Handle.build(:number => @number) end
Protected Instance Methods
fields()
click to toggle source
Returns the field rules to use when mapping to SOAP data
# File lib/economic/order_line.rb, line 31 def fields to_hash = proc { |handle| handle.to_hash } [ ["Handle", :handle, to_hash], ["Id", :number], ["Number", :number], ["OrderHandle", :order_handle, to_hash], ["Description", :description], ["DeliveryDate", :delivery_date, nil, :required], ["UnitHandle", :unit_handle, to_hash], ["ProductHandle", :product_handle, to_hash], ["Quantity", :quantity], ["UnitNetPrice", :unit_net_price, nil, :required], ["DiscountAsPercent", :discount_as_percent], ["UnitCostPrice", :unit_cost_price], ["TotalNetAmount", :total_net_amount, nil, :required], ["TotalMargin", :total_margin], ["MarginAsPercent", :margin_as_percent], ["DepartmentHandle", :department_handle, to_hash], ["DistributionKeyHandle", :distribution_key_handle, to_hash], ["InventoryLocationHandle", :inventory_location_handle, to_hash] ] end