Class: Reception

Inherits:
ApplicationRecord show all
Extended by:
NestedValidation
Defined in:
app/models/reception.rb,
app/models/reception/resource_factory.rb,
app/models/reception/unknown_library_type.rb

Overview

A reception handles the import of samples and requests from external sources While it is not necessary to persist it, is does provide a useful point for auditing and event tracking purposes.

Defined Under Namespace

Classes: LibraryTypeHelper, ResourceFactory, UnknownLibraryType

Constant Summary collapse

TOL_LAB_SHARE_SOURCE =

Source string used in tol-lab-share publish message We need to ensure this string stays consistent across repos

'tol-lab-share.tol'

Instance Method Summary collapse

Methods included from NestedValidation

validates_nested

Instance Method Details

#publish_source?Boolean

Used to determine whether the reception resources need publishing to the warehouse Currently only tol manifests require publishing (and compound samples via resource_factory)

Returns:

  • (Boolean)


31
32
33
# File 'app/models/reception.rb', line 31

def publish_source?
  [TOL_LAB_SHARE_SOURCE].include? source
end