Class: PlateHelper::WellFailingPresenter

Inherits:
BasicObject
Defined in:
app/helpers/plate_helper.rb

Overview

Proxy object wrapping the form alongside the presenter. This allows us to use the shared plate partial, but pass the form object through to the custom aliquot partial rubocop:disable Rails/HelperInstanceVariable

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(form, presenter) ⇒ WellFailingPresenter

Returns a new instance of WellFailingPresenter.



9
10
11
12
# File 'app/helpers/plate_helper.rb', line 9

def initialize(form, presenter)
  @form = form
  @_presenter = presenter
end

Instance Attribute Details

#_presenterObject (readonly)

Returns the value of attribute _presenter.



19
20
21
# File 'app/helpers/plate_helper.rb', line 19

def _presenter
  @_presenter
end

#formObject (readonly)

Returns the value of attribute form.



19
20
21
# File 'app/helpers/plate_helper.rb', line 19

def form
  @form
end

Instance Method Details

#aliquot_partialObject



14
15
16
# File 'app/helpers/plate_helper.rb', line 14

def aliquot_partial
  'well_failing_aliquot'
end