Sha256: cf0c973bb45c42b56b07665d350b0350d40e3059aee2e65c750411436ff62db0

Contents?: true

Size: 314 Bytes

Versions: 6

Compression:

Stored size: 314 Bytes

Contents

module NetSuite
  module RecordSupport
    include AttributeSupport

    def to_record
      attributes.inject({}) do |hash, (k,v)|
        hash.store("listRel:#{k.to_s.lower_camelcase}", v)
        hash
      end
    end

    def record_type
      "listRel:#{self.class.to_s.split('::').last}"
    end

  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
netsuite-0.0.10 lib/netsuite/record_support.rb
netsuite-0.0.9 lib/netsuite/record_support.rb
netsuite-0.0.8 lib/netsuite/record_support.rb
netsuite-0.0.7 lib/netsuite/record_support.rb
netsuite-0.0.6 lib/netsuite/record_support.rb
netsuite-0.0.5 lib/netsuite/record_support.rb