Custom field types - LabCollector

Search Knowledge Base by Keyword

You are here:
← All Topics

For each type of custom field, you will see in this KB screenshots that would help you with the creation process, editing records, and viewing record modes.

Take note that creating and modifying custom fields requires an admin or super-admin account.
Actions for viewing/using/editing each field after they are created can be done with other user account types in the modules.  

 

Selecting Custom fields brings up the following screen:

For each type of custom field, you will see in this KB screenshots for:

  • Creation step
    To create custom fields, go to ADMIN > Data > Custom fields and choose your module on the left. You can also refer to KB-Create custom field and KB-Create custom field 5.2v
  • Editing record:
    When you create a record (Add new record button on the top right of each module) or, if the record exists, use the icon at the right of the summary line of your record.
  • Record mode:
    The view record mode corresponds in each module to the view when you use the icon  at the left of the record summary line.

1. Text field

They can have fixed (50, 100, 250 characters), medium size, or unlimited size (text editor).

Creating a Text Field:


Since v5.42, the text field allows you to disallow values that don’t match with the value inside one of the text field of the same module.



Editing a Text Field:
Text Fields limited to 50, 100 or 250 characters appear as a single line when making edits. The text editor tool only appear if medium or long text is selected.


Record view mode:

2. Phone number

This field allows adding a phone number:

Creation step

Editing:

Record view:

 

3. Decimal number

It produces an empty field area on the form which can be filled by decimal numbers.

Creation step

Note
Kindly be aware that the options emphasized in red (refer to screenshot above) can solely be accessed upon purchasing the “compliance” pack. Please, don’t hesitate to reach out to our specialists at [email protected] for further information.

Since v5.3, aberration verification can be setup. If you enter at least 5 values in the same range, all values outside the average (+/- standard deviation) will give you an alert message.
Since v5.4, you now have the ability to enforce minimum and maximum values.

Editing:

Record view:

4. Autocomplete fields

They allow you to complete field with an autocomplete system based on record name from the module you choose.
This function is very useful to quickly create a link to another related record by simply entering 1-2 letters of the linked record name. This field type is necessary to create a search in field. See Search into section in this KB.

Remember that the autocomplete field links are links related to the Record name and the record ID. Hence, you can create the link before the record data is created and the link works or is activated as soon as the record is creates. However, you need to take care, because if you try to edit the name of the record after the link is created, it will not work.

Creation step:

 

Tips/Hints

There are several customization options in the autocomplete field as shown in the screenshot you provided. Here’s a detailed explanation of each option:

  • Default (field will present existing records as a helper): This option allows the field to display suggestions of existing records from the chosen module as you type. The autocomplete function is based on the record names, making it easy to link a new entry to an existing record. By default, it helps users avoid creating duplicate entries and enhances data entry speed.
  • Restrict values to match existing records of the target module: If checked, this option ensures that only values from the existing records in the selected module can be entered. It prevents users from inputting any new or unmatched entries, ensuring consistency and accuracy in the data.
  • Automatically select the value based on the record name: When enabled, this setting will pre-fill the autocomplete field with the most likely match as soon as the user starts typing. It speeds up data entry by suggesting and pre-selecting a value without needing the user to fully type or select it manually.
  • Manual Create (when empty field creates a new record after user manual confirmation): This option allows users to manually create a new record if no existing record matches the entered value. The creation of the new record will only happen after the user confirms it, providing flexibility while ensuring no accidental data entry.
  • Automatic Create (when empty field creates a new record automatically): This setting creates a new record automatically when the user enters a value not already in the database. It can be useful for situations where users frequently need to add new records, but there’s a higher risk of duplicates or unintended entries without manual verification.
  • Automatic Match & Fill (automatic fill fields based on same name with values retrieved from source module): When selected, this setting automatically matches the record in the autocomplete field with records from the source module and fills in related fields with the associated data. It’s especially useful when multiple fields in a form are dependent on one another, as it reduces the need for repetitive data entry.


Editing:

Record view:

The link is active, and when you click on it, the associated record opens in a new tab of your browser.


5. Search Into

This field allows the link of one master record to several sub-records in another module. If you have created an autocomplete field first (see section 3 of this KB), this field allows you to make a search on autocomplete fields. This function allows you to show a list of record links.

Creation step:

Choose the module where you created your autocomplete field, then proceed to select the corresponding autocomplete field.

Editing:
There is no modification mode for such field, LabCollector does the search automatically. All you have to do is fill the autocomplete field.

Record view:

When you click on the link (Related records in “Samples”) (as shown in the screenshot above), a new tab will open inside the selected module, where LabCollector searches automatically all the records with the corresponding autocomplete field.


6. NCBI autocomplete fields

They allow you to complete fields with an autocomplete system based on NCBI records from the database you choose.
This function is very useful to quickly create a link to NCBI records by simply entering the number of letters that you choose (edit the field) of the NCBI record name.

Creation step

Editing:
Based on Taxonomy NCBI database. First, select the genus then the species in the selection list.

Record view:
The field is filled with genus + species and the NCBI link to this genus record.


7. URL link

This type of field allows a link to be saved and displayed as a clickable Internet or server address.


8. GPS coordinates

This type of field allows a link to google maps. Coordinates must be in decimal degrees format.


Editing:

Record view:

See just below:

URL link opens directly a new tab with the URL.

GPS coordinates link opens a google map tab.



9. Select list

These fields have predefined values presented as a list. Only one choice is possible.
You can add as many as values as you want.

You can also use this type of field to organize your record and thus create value dependent fields. See the KB-custom field: Field category option v5.2x for more details.

Creation step


Once created, you need to enter in the field options on the right .


  1. Add a value
  2. Give a name
  3. If you check this box, this value will be the default value.
  4. When it’s possible (not used), you can delete this value with this button
  5. Save values
  6. If you have a lot of values to add, you can upload a CSV file with one column.

Editing:


All level permission except user can add value during edition by using Add/Edit values link.

Record view:


10. Multiple choice select list

These fields have predefined values presented as a list. Multiple choices are possible. You can also use this type of field to organize your record and thus create value dependent fields. See the KB-custom field: Field category option v5.2x for more details.

Creation step

Values can be edited and configured as for select list values.

Editing:

 

Use the CTRL key to select more than one value.

Record view:

See just below.
All level permission except user can add value during edition by using Add/Edit values link.

11. YES/NO select

This field has two predefined values: YES and NO. Only one choice is possible.

You can also use this type of field to organize your record and thus create value dependent fields. See the KB-custom field: Field category option v5.2x for more details.

Creation step:


Editing:


Record view:

12. Checkbox

These fields can give predefined options to check. Multiple choices can be checked. You can also use this type of field to organize your record and thus create value dependent fields. See the KB-custom field: Field category option v5.2x for more details.
Editing:


All level permission except user can add value during edition by using Add/Edit values link.

Record view:

13. Date

This field is a text box with a pre-formatted date. A calendar appears to choose the correct date easily or you can use the button TODAY for the date of the current day. The custom field calendar accepts years from 1900.

The Date Field Type allows you to set a date and associated features, such as alerts or conditions. Below is a detailed explanation of the options available for the Date field type:

Creation step:

You will have the option of setting up an alert for this date if you wish to use it for the purposes of an expiry date for example. Set Alerts Active to Yes and you can then specify the duration of the alert period by completing the fields Start Alerts and End Alerts.


1. Date:
– Check the box to activate the field and allow for date selection.

2. Alerts Active:
– If enabled, the system can trigger alerts based on the chosen date.
– Alerts are useful for notifying users when a date (such as an expiration or due date) is approaching.
– When activated, additional options for alerts will appear.

Allow Date Options:

There are multiple options to control date conditions:

  • =>: This means “equal to or greater than” the selected date. Example: Allow records with dates on or after today’s date.
  • >: This means “strictly greater than” the selected date. Example: Allow records only if the date is after today, i.e., no past records allowed.
  • =<: This means “equal to or less than” the selected date. Example: Allow records on today’s date or before.
  • <: This means “strictly less than” the selected date. Example: Allow records only if the date is in the past.

Date Selection:
You can set up multiple conditions for the date using checkboxes and selecting specific values. You can for example allow dates starting from today, or specify other dates, such as in 2024, by setting custom conditions.

Start Alerts:
This field defines how many days before the set date an alert should start. For example, If the alert is linked to an expiry date and you set “Start Alerts” to 10 days, the alert will activate 10 days before the set date.

Alerts after Date:
You can define how many days after the set date the alert should remain active. If you want the alert to remain for 5 days after the selected date, set the value to 5.

Alert Duration:
You can define how many days the alert should be active during a specific period. For example, If the event or action related to the date has a 7-day window, set this value to 7 days.

Disable Alert When:
This option provides conditional logic to disable the alert based on other conditions in the record. For example, you can configure the alert to disable when certain criteria (value of selected field) meet a specific condition such as “Equal” to a value.

Editing:


Record view:


If you set up an alert, you will have an entry in the tab ALERTS:

14. Time

This field is a text box with pre-formatted time. A select list from 00:00:00 to 23:30:00 appears to choose the time easily or you can use the button NOW for the current time.  Use with care if you have multiple sites in different time zones.

Editing:

15. Datetime

This field is a text box with pre-formatted date and time. A calendar appears to choose the correct date easily. Then, a select list from 00:00:00 to 23:30:00 appears to choose the time easily or you can use the button NOW for the current date + time.


16. Disk folder upload

With this field, users can store document files directly into LabCollector. Files are then accessible from the record itself.
For image files, this custom field type shows an image preview in the record directly.

Editing:

Just click on the Upload button to find your file. All file types are supported.

If you want to delete a file, just select it by clicking on the text (as shown in the screenshot above), then hit Save.

Record view:

Above is an example with a PDF file. Use the link to download the file.


Above is an example of the record view if you choose to upload an image.

In version 5.4 and above it is also possible to preview CSV files:

You can minimize this preview also with the  icon on the top right.

Tips/Hints
When you click on an image, a bigger view in a fancybox is opened, you also have the possibility to download the image. (See screenshot below for an example). Same goes for Disk folder upload field type.

 

17. Link

This field type allows you to link your new record to another one in any module. Multiple links can be added in the same field.
You can restrict to one module or leave the link open (no pre-selected module).

Creation step:

Here is an example where you restrain the search to a unique module.

In version 5.4 and above, it is possible to link to specific lots from Reagents & Supplies by choosing Lots from the dropdown “Any Module” (see image below). Again, this can be restricted here in the Custom Field settings or it can be chosen at the time of adding/editing a record.

In version 5.41 and above, it is possible to assign a condition to the link. Check the box, choose the field in the linked module where the condition will be applied, select the condition (Equal, Not equal, Lower than, Greater than, Contains) and the conditional value.
For example, below, the user will be able to select only the female animal. Version 5.42 brings the possibility to have 2 conditions and to limit one link per record.

Editing:

Click on “Pick” button to select other records. You can use the search function and select all the records using the + button.

In version 5.41 and above, the records can be searched using their barcodes.

Record view:

Each link is active and opens a new tab.

18. Tracking link

This field type allows you to use a general URL and then to associate a specific ID to each record. It is useful to follow shipments for example.

Creation step:


Under the setup tab when you create the field, enter the general URL. Here for example, the URL corresponding to our Knowledge base.

 

Editing:

In the field, only enter the ID/the variable corresponding to the tracked element.

Record view:
The link is active and opens a new tab.

19. User Select List

This field allows choosing a user in the list of LabCollector users.

Editing:

20. Line separator

This last field type is for design. It allows you to divide your record into sections for easier viewing. Place fields of each section, below this field.
Under the search options, this line separator appears like a folder to organize your search filters by section.
Under Analysis tab, this line separator appears like tabs to organize your fields (see section Analysis tab in KB-Create custom fields or in KB-custom field: tab analysis)

Editing:

Record view:

Under the search options, the line separator is a folder in which you find the fields with filter option.

21. Calculated Field

This field allows using a formula on a decimal field and datetime field (and other calculated fields) to have an automatic result in the field in view mode.
If you need to include decimal, datetime or calculated fields from other module, the function “block duplicates ” has to be activated (1:1), and the relation between the two records is performed on the record’s name.
If the function “block duplicates ” is not activated (1:N) in the second module, only SUM and AVG function are available.

There is the function Age, useful with animal and patient records. You can chose between AGE_Y (years), AGE_M (months) or AGE_D (days). This calculation will be dependent on a DOB (date of birth) field of the record.

You also have the option to add a text with the “Add literal” tab located to the right. Please, make sure to include a | (vertical bar) between each field in order for the concatenation to be valid.

New (v6.01)
Autocomplete fields have been added to the list of fields allowed in formulas of calculated fields.

Creation step:

Drag and drop the fields in the formula box as needed.

1. Mathematical Calculations:
– You can create fields that automatically compute values based on existing numeric fields.
– Common operations like addition (`+`), subtraction (`-`), multiplication (`*`), and division (`/`) can be used.
– The system also supports parentheses for grouping operations and applying precedence in calculations.
Example: If you have a field for the weight of an object and another field for its quantity, you can create a calculated field for the total weight: Total Weight = weight * quantity

2. Concatenation of Text Fields:
– The Calculated Field Type allows the concatenation of text fields, enabling you to combine strings from different fields into one.
– This can be useful for creating unique identifiers, product descriptions, or even creating labels that combine text from different sources.
Example: You have a first name field and a last name field. You can concatenate them to form a full name: Full Name = First Name + ” ” + Last Name

3. Support for Text Fields:
– In addition to performing numerical calculations, you can also use text fields within the calculated fields.
– This is useful for creating dynamic text outputs or combining numerical calculations with static text.
Example: You can create a field that appends the result of a numeric calculation to some literal text. Suppose you have a field called Age: Age Text = Age + ” years old”

4. Adding Literals and Custom Strings:
– You can also add literals or static text into the calculation fields, offering more control over how data is displayed.
– To differentiate between literals, variables, or calculated values, you can use the vertical bar `|` as a separator. This allows for a clear and structured combination of values.
Example: To display a label that combines name, age, and a custom string, you could use: Label = “Name: ” | First Name + ” ” + Last Name | “, Age: ” | Age + ” years”

Example of Age Calculation:

Suppose you want to calculate someone’s age based on their date of birth (DOB) and today’s date. You can achieve this by using a calculated field with a formula that subtracts the year of the birth date from the current year:

Formula: Age = YEAR(Today) – YEAR(DOB)

You can also combine this with custom text to output something like: “Person is ” | Age | ” years old”

Editing:
There is no edition mode for such field, LabCollector does the calculation automatically.

Record view:

Related topics: