Class: Presenters::PcrCyclesBinnedPlatePresenterBase

Inherits:
PlatePresenter show all
Includes:
Statemachine::Standard
Defined in:
app/models/presenters/pcr_cycles_binned_plate_presenter_base.rb

Overview

The PcrCyclesBinnedPlatePresenter is used for plates that have had pcr cycle binning applied. It shows a view of the plate with colours and keys indicating the various bins. This is the base class for the PcrCyclesBinnedPlatePresenter and should not be used directly. NB. Once DuplexSeq is converted to use the new request poly_metadata, this subclassing can be removed and the PcrCyclesBinnedPlateUsingRequestMetadataPresenter version will be the only version needed.

Instance Method Summary collapse

Instance Method Details

#bin_detailsObject



34
35
36
# File 'app/models/presenters/pcr_cycles_binned_plate_presenter_base.rb', line 34

def bin_details
  @bin_details ||= dilutions_calculator.compute_presenter_bin_details
end

#bins_keyObject



30
31
32
# File 'app/models/presenters/pcr_cycles_binned_plate_presenter_base.rb', line 30

def bins_key
  dilutions_calculator.presenter_bins_key
end

#current_plateObject



22
23
24
# File 'app/models/presenters/pcr_cycles_binned_plate_presenter_base.rb', line 22

def current_plate
  @current_plate ||= Sequencescape::Api::V2.plate_with_custom_includes(current_plate_includes, uuid: labware.uuid)
end

#current_plate_includesObject



38
39
40
# File 'app/models/presenters/pcr_cycles_binned_plate_presenter_base.rb', line 38

def current_plate_includes
  raise 'Method current_plate_includes must be implemented in a subclass of PcrCyclesBinnedPlatePresenterBase'
end

#dilutions_calculatorObject



26
27
28
# File 'app/models/presenters/pcr_cycles_binned_plate_presenter_base.rb', line 26

def dilutions_calculator
  @dilutions_calculator ||= Utility::PcrCyclesBinningCalculator.new(well_details)
end