Class: CherrypickTask::PickTarget::ByRow

Inherits:
CherrypickTask::PickTarget show all
Defined in:
app/models/cherrypick_task.rb

Overview

Deals with generating the pick plate by travelling in a row direction, so A1, A2, A3 …

Instance Method Summary collapse

Methods inherited from CherrypickTask::PickTarget

#empty?, for, #full?, #initialize, #push

Constructor Details

This class inherits a constructor from CherrypickTask::PickTarget

Instance Method Details

#completed_viewObject


40
41
42
43
44
45
46
# File 'app/models/cherrypick_task.rb', line 40

def completed_view
  @wells.dup.tap do |wells|
    complete(wells)
  end.each_with_index.inject([]) do |wells, (well, index)|
    wells.tap { wells[@shape.horizontal_to_vertical(index + 1, @size)] = well }
  end.compact
end