Class: NetSuite::Records::ItemFulfillmentItem
Instance Method Summary
collapse
#record_namespace
#record_type, #to_attributes!
#record_namespace
#attributes, #attributes=, #initialize_from_attributes_hash
included
included
Constructor Details
#initialize(attributes_or_record = {}) ⇒ ItemFulfillmentItem
23
24
25
26
27
28
29
30
|
# File 'lib/netsuite/records/item_fulfillment_item.rb', line 23
def initialize(attributes_or_record = {})
case attributes_or_record
when Hash
initialize_from_attributes_hash(attributes_or_record)
when self.class
initialize_from_record(attributes_or_record)
end
end
|
Instance Method Details
#initialize_from_record(record) ⇒ Object
32
33
34
|
# File 'lib/netsuite/records/item_fulfillment_item.rb', line 32
def initialize_from_record(record)
self.attributes = record.send(:attributes)
end
|
#to_record ⇒ Object
36
37
38
39
40
41
42
|
# File 'lib/netsuite/records/item_fulfillment_item.rb', line 36
def to_record
rec = super
if rec["#{record_namespace}:customFieldList"]
rec["#{record_namespace}:customFieldList!"] = rec.delete("#{record_namespace}:customFieldList")
end
rec
end
|