Class: Models::ConsignmentProduct

Inherits:
Base
  • Object
show all
Defined in:
lib/models/consignment.rb

Instance Attribute Summary

Attributes inherited from Base

#client, #data

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Base

#base_record, #extra_records, #records, schema, stream, subclasses

Class Method Details

.pathObject



4
5
6
# File 'lib/models/consignment.rb', line 4

def self.path
  nil
end

Instance Method Details

#transformObject



12
13
14
15
16
17
18
19
# File 'lib/models/consignment.rb', line 12

def transform
  super.tap do |hash|
    hash.merge!(
      'id' =>
         hash.slice('consignment_id', 'product_id').values.join('.')
    )
  end
end