Class: NetSuite::Records::Transaction
- Inherits:
-
Object
- Object
- NetSuite::Records::Transaction
- Includes:
- Namespaces::TranSales, Support::Actions, Support::Fields, Support::RecordRefs, Support::Records
- Defined in:
- lib/netsuite/records/transaction.rb
Instance Attribute Summary collapse
-
#external_id ⇒ Object
Returns the value of attribute external_id.
-
#internal_id ⇒ Object
readonly
Returns the value of attribute internal_id.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(attributes = {}) ⇒ Transaction
constructor
A new instance of Transaction.
- #to_record ⇒ Object
Methods included from Namespaces::TranSales
Methods included from Support::Actions
Methods included from Support::Records
Methods included from Namespaces::PlatformCore
Methods included from Support::Attributes
#attributes, #attributes=, #initialize_from_attributes_hash
Methods included from Support::RecordRefs
Methods included from Support::Fields
Constructor Details
#initialize(attributes = {}) ⇒ Transaction
Returns a new instance of Transaction.
15 16 17 18 19 |
# File 'lib/netsuite/records/transaction.rb', line 15 def initialize(attributes = {}) @internal_id = attributes.delete(:internal_id) || attributes.delete(:@internal_id) @external_id = attributes.delete(:external_id) || attributes.delete(:@external_id) initialize_from_attributes_hash(attributes) end |
Instance Attribute Details
#external_id ⇒ Object
Returns the value of attribute external_id.
13 14 15 |
# File 'lib/netsuite/records/transaction.rb', line 13 def external_id @external_id end |
#internal_id ⇒ Object (readonly)
Returns the value of attribute internal_id.
12 13 14 |
# File 'lib/netsuite/records/transaction.rb', line 12 def internal_id @internal_id end |
Class Method Details
.custom_soap_advanced_search_record_type ⇒ Object
21 22 23 |
# File 'lib/netsuite/records/transaction.rb', line 21 def self.custom_soap_advanced_search_record_type 'tranSales:TransactionSearchAdvanced' end |
Instance Method Details
#to_record ⇒ Object
25 26 27 28 29 30 31 |
# File 'lib/netsuite/records/transaction.rb', line 25 def to_record rec = super if rec["#{record_namespace}:customFieldList"] rec["#{record_namespace}:customFieldList!"] = rec.delete("#{record_namespace}:customFieldList") end rec end |