eLabSDK.Page.SampleBrowser Class
Customize the SampleBrowser Page (context aware)
Constructor
eLabSDK.Page.SampleBrowser
-
object
Parameters:
-
object
Object-
onBeforePageLoad
Function- onBeforePageLoad Event
-
Item Index
Methods
Methods
addActionToSampleBrowser
-
id
-
content
-
callback
Parameters:
-
id
Object: button id
-
content
Object: button content
-
callback
Object: function to call on click
addBulkSampleAction
-
actionTitle
-
callback
(Deprecated, use registerBulkAction instead). Allows the creation of bulk sample actions in the sample list.
Parameters:
-
actionTitle
String: name of the action displayed in the selector
-
callback
Function: function to execute when the action is selected. Provide information on the chosen samples.
Returns:
in callback { sampleIDs: [], seriesIDs: [], sampleIDsIncludingSeriesClicked: [], sampleCount: 0, sampleTypeIDs: [] }
addContentToStorageUnitNode
-
storageID
-
htmlContent
-
toolTipContent:
Adds content to the tree node containing a particular storage unit
Parameters:
-
storageID
Object: storage unit ID
-
htmlContent
Object: content (in html) to add
-
toolTipContent:
ObjectAdditional content (in html) to add to the tooltip onhover
addPrintOption
-
btn
Insert a print option to the 'Print Compartment' button dropdown.
Parameters:
-
btn
Object: button configuration
Example:
addPrintOption(new eLabSDK.GUI.Button({ label: 'Test Print', icon: 'barcode', actionID: 'testButton', action: function () { return; } }) );
currentCompartmentView
()
String
Gets the current viewmode of the compartment.
Returns:
listview or boxview
focusSampleboxOrList
-
disableClicks
Focus on the samplebox or sample list in the GUI
Parameters:
-
disableClicks
Bool: Prevent any item to be clicked.
refreshSampleData
()
Refresh the sample data currently on screen
registerBulkAction
-
object
Register a bulk action for editing samples.
Parameters:
-
object
Object-
id
String- Unique ID of your action. We strongly advise to preface with your root identifier from your add-on.
-
label
String- make sure this is sufficiently unique to identify your add-ons action. If the label exists, the action will not be added to the menu.
-
onSelect
Function- callback function returning a list of sampleIDs and sampleSeriesIDs, and where applicable partialSampleSeriesIDs selected.
-
removeFocusSampleboxOrList
()
Removed focus on the samplebox or sample list in the GUI
removeSampleTypesFromAddDialog
-
object
Removes all sample types from the possible options during the Sample Add action, except for the ones specified. Only call this after the onAddNewSample event
Parameters:
-
object
Object-
keepIDs
String- Array of sampleTypeIDs
-
restoreTransposedSampleBoxes
()
Restore transposed boxes in the GUI to change the direction of cells back to the default.
transposeSampleBoxes
()
Transpose box GUI to change the direction of cells from top to down, left to right.
transposeStoragePrint
()
Transpose box GUI to change the direction of cells from top to down, left to right. This overrides the printing feature