Class: Request::AutoMultiplexing
- Inherits:
-
Multiplexing
- Object
- ActiveRecord::Base
- ApplicationRecord
- Request
- CustomerRequest
- Multiplexing
- Request::AutoMultiplexing
- Defined in:
- app/models/request/auto_multiplexing.rb
Overview
In the Generic Lims, transfer into the Multiplexed library tube is triggered automatically when the plate is passed. However, if multiplexing decisions are made after library creation, this step has already taken place. This callback ensure that the tube are generated after the submission is complete. The user may then log into generic Lims to see their plates. This issue is avoided in Limber by decoupling tube creation from plate passing allowing the step to be repeated at any time. This class can be removed if either the generic LIMS behaviour is updated, or moved into Limber.
Constant Summary
Constants included from Metadata
Constants included from Statemachine
Statemachine::ACTIVE, Statemachine::COMPLETED_STATE, Statemachine::INACTIVE, Statemachine::OPENED_STATE, Statemachine::SORT_ORDER
Constants included from StandardNamedScopes
StandardNamedScopes::SORT_FIELDS, StandardNamedScopes::SORT_ORDERS
Instance Method Summary collapse
-
#register_transfer_callback ⇒ Object
Triggers immediate transfer into the tubes if the source asset already exists.
Methods inherited from Multiplexing
Methods inherited from CustomerRequest
#customer_accepts_responsibility!, #generate_create_request_event, #generate_destroy_request_event, #generate_request_event, #update_responsibilities!
Methods inherited from Request
accessioning_required?, #add_comment, #aliquot_attributes, #associated_studies, #cancelable?, #copy, #current_request_event, #customer_accepts_responsibility!, delegate_validator, #detect_descriptor, #eventful_studies, for_study, #format_qc_information, get_all_comments, #has_passed, #lab_events_for_batch, #manifest_processed!, #most_recent_event_named, #next_request_type_id, #next_requests, #next_requests_via_asset, #next_requests_via_submission, number_expected_for_submission_id_and_request_type_id, #previous_failed_requests?, #priority, #product_line, #project=, #project_id=, #ready?, #request_type_updatable?, #return_pending_to_inbox!, #run_events, #source_labware, #study=, #study_id=, #submission_plate_count, #submitted_at, #target_purpose, #target_tube, #update_pool_information, #update_priority, #update_responsibilities!
Methods included from Statistics
#asset_statistics, #progress_statistics, #sample_statistics_new
Methods included from EventfulRecord
#has_many_events, #has_many_lab_events, #has_one_event_with_family
Methods included from Metadata
Methods included from CustomerResponsibility
Methods included from Batch::RequestBehaviour
included, #recycle_from_batch!, #return_for_inbox!, #with_batch_id
Methods included from Statemachine
#cancellable?, #change_decision!, #closed?, #failed_downstream!, #failed_upstream!, #finished?, #on_blocked, #on_cancelled, #on_failed, #on_hold, #on_passed, #on_started, #open?, #terminated?, #transfer_aliquots
Methods included from StandardNamedScopes
Methods included from Commentable
Methods included from AASM::Extensions
Methods included from Uuid::Uuidable
included, #unsaved_uuid!, #uuid
Methods included from Api::RequestIo::Extensions
Methods included from Aliquot::DeprecatedBehaviours::Request
Methods inherited from ApplicationRecord
alias_association, convert_labware_to_receptacle_for, find_by_id_or_name, find_by_id_or_name!
Methods included from Squishify
Instance Method Details
#register_transfer_callback ⇒ Object
Triggers immediate transfer into the tubes if the source asset already exists. This allows multiplexing requests to be made on plates at the end of library prep, after the plate is qc_complete. If no asset is present then we haven’t got to that stage yet and transfer will be triggered as part of the standard workflow.
18 19 20 21 22 23 24 25 |
# File 'app/models/request/auto_multiplexing.rb', line 18 def register_transfer_callback # We go via order as we need to get a particular instance of submission return if asset.blank? order .submission .register_callback(:once) { Transfer::FromPlateToTubeByMultiplex.create!(source: asset.plate, user: order.user) } end |