eLABSDK V1.0

API Docs for: 1.0.0
Show:

eLabSDK.Inventory.Sample

Extends ELabSDK
Module: eLabSDK

Summary

Print labels

Constructor

eLabSDK.Inventory.Sample

Syntax

eLabSDK.Inventory.Sample

(
  • object
)

Summary

Parameters:

  • object Object

Example:

  • var sample = eLabSDK.Inventory.Sample.create({
              name: 'My Sample',
              sampleTypeID: 1,
              fnWhenReady: function(config, sample){alert('sample created with name ' + sample.getName())}
    });
    

Methods

eLabSDK.Inventory.Sample.create (STATIC) - creates a new sample and triggers the load function

Syntax

eLabSDK.Inventory.Sample.create (STATIC) - creates a new sample and triggers the load function

(
  • config
  • fnWhenReady
)

Summary

Parameters:

  • config Object
    • name Name
    • sampleTypeID Int
    • storagelayerID Int
    • location String
    • quantity Int
    • quantity_amount Int
    • quantity_unit String
    • expiration String
    • altBarcodeID Int
    • note String
    • meta[{ Object

      value: "value", key: "test", type:'text'}]

  • fnWhenReady Function

    called when the Sample has actually been created. Place your code logic within this callback. First parameter is the original config object, second is the actual sample

Returns:

New instance of eLabSDK.Inventory.Sample

getBarcode - returns the barcode value of the current sample

Syntax

getBarcode - returns the barcode value of the current sample

()

Summary

getDescription - returns the description value of the current sample

Syntax

getDescription - returns the description value of the current sample

()

Summary

getMeta - returns the meta value of the current sample

Syntax

getMeta - returns the meta value of the current sample

()

Summary

getName - returns the name value of the current sample

Syntax

getName - returns the name value of the current sample

()

Summary

getNotes - returns the notes value of the current sample

Syntax

getNotes - returns the notes value of the current sample

()

Summary

getPropertyByName - returns the value of the passed in propertyname

Syntax

getPropertyByName - returns the value of the passed in propertyname

(
  • propertyname
)

Summary

Parameters:

  • propertyname String

getPropertyBySampleMetaID - returns the property object[] (key/value) by sampleMetaID

Syntax

getPropertyBySampleMetaID - returns the property object[] (key/value) by sampleMetaID

(
  • sampleTypeMetaID
)

Summary

Parameters:

  • sampleTypeMetaID Int

getPropertyBySampleTypeMetaID - returns the property object[] (key/value) by sampleTypeMetaID

Syntax

getPropertyBySampleTypeMetaID - returns the property object[] (key/value) by sampleTypeMetaID

(
  • sampleTypeMetaID
)

Summary

Parameters:

  • sampleTypeMetaID Int

initialize - innitialises the Sample class and loads a sample if during the init config data was passed through

Syntax

initialize - innitialises the Sample class and loads a sample if during the init config data was passed through

(
  • sampleIDs
  • fnWhenReady
)

Summary

Parameters:

  • sampleIDs String
  • fnWhenReady Function

remove - removes the current sample

Syntax

remove - removes the current sample

(
  • fnWhenReady
)

Summary

Parameters:

  • fnWhenReady Function

save - saves the sample

Syntax

save - saves the sample

(
  • fnWhenReady
)

Summary

Parameters:

  • fnWhenReady Function

setDescription - sets the description string for the current sample

Syntax

setDescription - sets the description string for the current sample

(
  • description
)

Summary

Parameters:

  • description String

setMeta - sets the meta key/value for the current sample

Syntax

setMeta - sets the meta key/value for the current sample

(
  • sampleMetaData
)

Summary

Parameters:

  • sampleMetaData Objectkey,value

setName - sets the name string for the current sample

Syntax

setName - sets the name string for the current sample

(
  • name
)

Summary

Parameters:

  • name String

setNotes - sets the note string for the current sample

Syntax

setNotes - sets the note string for the current sample

(
  • note
)

Summary

Parameters:

  • note String