Class: SangerSampleId

Inherits:
ApplicationRecord show all
Defined in:
app/models/sanger_sample_id.rb

Overview

rubocop:todo Style/Documentation

Defined Under Namespace

Classes: Factory

Class Method Summary collapse

Methods inherited from ApplicationRecord

convert_labware_to_receptacle_for, find_by_id_or_name, find_by_id_or_name!

Methods included from Squishify

extended

Class Method Details

.generate_sanger_sample_id!(study_abbreviation, sanger_id = nil) ⇒ Object


16
17
18
# File 'app/models/sanger_sample_id.rb', line 16

def generate_sanger_sample_id!(study_abbreviation, sanger_id = nil)
  "#{study_abbreviation}#{sanger_id || SangerSampleId::Factory.instance.next!}"
end