Class: Tasks::AddSpikedInControlHandler::Handler
- Inherits:
-
BaseHandler
- Object
- BaseHandler
- Tasks::AddSpikedInControlHandler::Handler
- Defined in:
- app/models/tasks/add_spiked_in_control_handler.rb
Overview
The handler takes the parameters for the task and helps add the scanned Spiked PhiX as a parent of each lane
Instance Attribute Summary
Attributes inherited from BaseHandler
#controller, #params, #task, #user
Instance Method Summary collapse
Methods inherited from BaseHandler
Constructor Details
This class inherits a constructor from Tasks::BaseHandler
Instance Method Details
#perform ⇒ Object
8 9 10 11 12 13 14 15 |
# File 'app/models/tasks/add_spiked_in_control_handler.rb', line 8 def perform # Rubocop gets in a fight with prettier here. if .present? return false, "Can't find a spiked hybridization buffer with barcode #{.to_sentence}" end Batch.transaction { add_control ? create_batch_events : false } end |