Class: Api::V2::QcableResource

Inherits:
BaseResource
  • Object
show all
Defined in:
app/resources/api/v2/qcable_resource.rb

Overview

Provides a JSON API representation of Qcable See: jsonapi-resources.com/ for JSONAPI::Resource documentation

Instance Method Summary collapse

Methods inherited from BaseResource

apply_includes, default_includes, inclusions, resolve_relationship_names_to_relations, updatable_fields

Instance Method Details

#labware_barcodeObject

Custom methods These shouldn't be used for business logic, and are more about I/O and isolating implementation details.


31
32
33
34
35
36
37
# File 'app/resources/api/v2/qcable_resource.rb', line 31

def labware_barcode
  {
    'ean13_barcode' => _model.ean13_barcode,
    'machine_barcode' => _model.machine_barcode,
    'human_barcode' => _model.human_barcode
  }
end