Skip to main content

Fields Overview

Each form page contains a fields component that defines user input areas. Each field supports specific types and configurations.

Fields overview

Structure of fields

PropertyTypeRequiredDescription
keyobjectNoUnique identifier for the field.
optionsobjectNoDisplay name of the field.
htmlobjectNoHTML content to be displayed.
note

html is a special property that allows you to add HTML content to the form. I can't be used with key or options at the same time.

key properties

PropertyTypeRequiredDescription
idstringYesUnique identifier for the field.
labelstringYesDisplay name of the field.
labelsobjectNoTranslated versions of label. See page about languages
requiredbooleanNoSpecifies if the field is mandatory for form submission.
fieldtypestringYesThe field to be used.
defaultValuestringNoDefault value of the field. Can reference a custom field, a post value, or be a fixed string.
getOptionsFromstringNoFetches options from a specific field.

Field Types & Configuration

Basic Field Structure

{
"key": {
"id": "field_id",
"label": "Field label",
"required": false,
"fieldtype": "text | number | float | finance | email | phone | ...",
"defaultValue": "optional default value"
}
}

Default Value Variants

  • Empty: No defaultValue provided.
  • Fixed: A static value (e.g., "My default", 42).
  • Dynamic: Uses a placeholder like [project.cf1234].

Example Field Types

Text Field

"fieldtype": "text",
"defaultValue": "Inspection of site" // or [project.cf1234]

Number / Float / Finance

"fieldtype": "number" | "float" | "finance",
"defaultValue": 12345 // or [project.cf5678]

Email / Phone

"fieldtype": "email" | "phone",
"defaultValue": "user@example.com" // or [project.cf9101]

Option Fields

Used for dropdowns, radio buttons, or checkboxes.

Shared Option Structure

"options": [
{ "id": "1", "value": "Option 1" },
{ "id": "2", "value": "Option 2" }
]

Types

  • dropdown
  • radio
  • checkbox (supports multiple selections)

Example Configuration

"fieldtype": "dropdown",
"defaultValue": "2"

Date and Time Fields

"fieldtype": "date" | "clock",
"defaultValue": "2024-01-01" | "[datenow]" | "[timenow]" | "[project.cf...]"

User & Group Fields

Allow selecting users, groups, or both. Can include metadata restrictions.

Metadata Example

"metadata": {
"allowUsersFromGroups": "group_inspectors"
}

Address Lookup Fields

Integrated with map services and allows toggling specific address parts.

"metadata": {
"showFieldLatitude": false,
"showFieldLongitude": false,
"showFieldCountry": false,
"showFieldCity": false,
"showFieldZip": false,
"showFieldStreet": false,
"showFieldFormattedAddress": false
},

Prefilled Values

"valueFieldCity": "[project.cf691]"

HTML Fields

Used to add custom display elements in forms.

Example

{
"html": {
"tag": "h3",
"label": "Project Section",
"labels": {
"da_dk": "Projektafsnit",
"pl_pl": "Projekt sekcja"
}
}
}