Class: ItemBuilderMwh::Modes::BaseService
- Inherits:
-
Object
- Object
- ItemBuilderMwh::Modes::BaseService
- Defined in:
- lib/item_builder_mwh/modes/base_service.rb
Instance Attribute Summary collapse
-
#listing ⇒ Object
readonly
Returns the value of attribute listing.
Instance Method Summary collapse
-
#initialize(args) ⇒ BaseService
constructor
A new instance of BaseService.
- #perform ⇒ Object
Constructor Details
#initialize(args) ⇒ BaseService
Returns a new instance of BaseService.
8 9 10 |
# File 'lib/item_builder_mwh/modes/base_service.rb', line 8 def initialize(args) @listing = args.fetch(listing) end |
Instance Attribute Details
#listing ⇒ Object (readonly)
Returns the value of attribute listing.
7 8 9 |
# File 'lib/item_builder_mwh/modes/base_service.rb', line 7 def listing @listing end |
Instance Method Details
#perform ⇒ Object
12 13 14 15 16 17 18 19 |
# File 'lib/item_builder_mwh/modes/base_service.rb', line 12 def perform { id: listing.id, local_id: listing.local_id, local_item_id: listing.local_item_id, sku: listing.sku } end |