Skip to Content
AdministrationForm Builders

Form Builders

Almost every question SeqDesk asks a researcher is configurable. Three separate builders own three separate forms:

BuilderScreenGoverns
Sequencing Order Form/admin/form-builderThe intake wizard at /orders/new and the sample table inside a sequencing order
Study Forms / Define Studies/admin/study-form-builder, or /admin/study-definitions when the dynamic-studies module is onThe study questionnaire
Sequencing Run Fields/admin/sequencing-run-form-builderThe per-sample questionnaire on a sequencing run’s assignment table

They share the same field model — type, label, visibility, required, help text, validation — but they are stored separately and edited separately. Nothing you do in one affects the others.

The order and study builders autosave. Roughly 1.2 seconds after you stop editing, the configuration is written and becomes live for researchers; the header shows Unsaved changes, then Saving changes…, then the saved state. There is no “publish” step and no draft mode. Export the current configuration before a large restructuring — that export is your only rollback.

Sequencing Order Form Builder

Five tabs across the top of /admin/form-builder:

TabContents
Per-Sequencing Order FieldsQuestions answered once per order, plus suggested field templates
Per-SampleQuestions answered for every sample, rendered as columns in the sample table
Facility FieldsAdmin-only fields, at order level and sample level, never shown to researchers
SettingsPost-submission instructions and data-handling policy
Import / ExportExport, import, and reset to defaults

How the wizard is assembled

The order wizard at /orders/new is generated from the configuration:

  1. Each section becomes a wizard step, in section order.
  2. Fields appear in the step matching their section.
  3. The Samples step always appears and renders the per-sample fields as table columns.
  4. A Review step is always last.

Sections are fixed

The order form has exactly two user-facing sections and you cannot add more: group_details (“Sequencing Order Details”) and group_sequencing (“Sequencing Information”). Older exports that contain custom groups still import — their fields are mapped into one of the two fixed sections by keyword, with sequencing-related fields (platform, library, instrument, technology, read, software) landing in Sequencing Information and everything else in Sequencing Order Details.

Per-sample fields, facility-only fields and MIxS fields are exempt from this mapping — they are placed by their tab, not by a section.

System fields

These ship with every instance. They can be shown, hidden, relabelled or made required, but not deleted.

Sequencing Order Details

FieldTypeDefault
Sequencing Order NametextVisible, optional. The order number ORD-YYYYMMDD-XXXX is generated separately.
Number of SamplesnumberVisible, optional, valid range 1–500. Pre-fills the sample table.

Sequencing Information

FieldTypeDefault
Sequencing Technologysequencing-techVisible. Drives the cascading instrument selector.
Instrument ModeltextVisible, optional
Library StrategyselectVisible. WGS, WXS, RNA-Seq, AMPLICON, Bisulfite-Seq, ChIP-Seq, ATAC-seq, Other
Library SourceselectVisible. Genomic DNA, Metagenomic, Transcriptomic, Metatranscriptomic, Synthetic, Viral RNA, Other
Library SelectionselectVisible. Random, PCR, Random PCR, RT-PCR, Size Fractionation, cDNA, PolyA, Oligo-dT, Unspecified

Per-sample

FieldTypeDefault
OrganismorganismVisible and required. NCBI taxonomy lookup.
Sample TitletextVisible and required
Sample AliastextVisible, optional; can be auto-generated if left blank

Facility-only, shipped and admin-only from the start:

FieldTypeScope
Internal QC Statusselect — Pending, In Review, Passed, Needs Follow-upPer order
Internal NotestextareaPer order
Sample QC Resultselect — Pending, Passed, Failed, Repeat RequestedPer sample
Sample NotestextareaPer sample

Field types

TypeRenders asRequires
textSingle-line input
textareaMulti-line input
selectSingle-choice dropdown
multiselectMulti-choice dropdown
checkboxBoolean toggle
numberNumeric input with min/max
dateDate picker
mixsMIxS metadata selectormixs-metadata module
fundingFunding and grant blockfunding-info module
billingCost centre / PSP blockbilling-info module
organismNCBI taxonomy lookupena-sample-fields module
sequencing-techInstrument selectorsequencing-tech (always on)
barcodePer-sample barcode assignmentsequencing-tech (always on)

There is no email, phone, url or currency field type. Collect those with a text field and a Format preset under validation — email, url, phone or alphanumeric — or a custom regular expression.

Two placement rules are enforced by the model rather than by the UI:

  • mixs, funding, billing and sequencing-tech are order-level only.
  • organism and barcode are per-sample only.

Per-field settings

SettingEffect
LabelWhat the researcher sees
NameThe key the value is stored under in customFields (or the Order column, for system fields)
VisibleWhether the field is rendered at all
RequiredWhether it must be filled before the step can be completed
Per-sampleTable column versus once per order
Admin-onlyHidden from researchers; shown to facility admins only
Help textGuidance below the field
Placeholder, ExampleHints inside and beside the empty field
Default valuePre-filled on load
OptionsFor select and multiselect
ValidationMin/max length, min/max value, a Format preset or a custom pattern with a custom message
AI validationA prompt describing valid input plus a strictness of lenient, moderate or strict. Only when the ai-validation module is enabled

Fields can be reordered by drag and drop within and between sections.

Module dependencies

A field type whose module is off is hidden everywhere, regardless of the field’s own Visible setting. This is the fastest way to remove a whole class of questions.

ModuleAffects
mixs-metadatamixs fields
funding-infofunding fields
billing-infobilling fields
ena-sample-fieldsOrganism, Sample Title, Sample Alias
ai-validationEnables AI validation on any field; not itself a field type
sequencing-techsequencing-tech and barcode; always enabled, so these are always available

The study builder shows a banner — “N fields hidden because related modules are disabled” — with a link to Modules, which is the quickest way to diagnose a field that vanished.

The Settings tab

Advanced Settings holds two blocks that are not about fields at all:

  • Post-Submission Instructions — free text shown to a researcher after they submit a sequencing order. Use it for shipping addresses, labelling conventions and drop-off hours.
  • Data Handling — two switches, shared with Settings → Accounts:
SwitchEffect
Allow Deletion of Submitted Sequencing OrdersLets facility admins delete an order after submission. Useful for testing; leave it off in production, because deleting an order destroys its samples.
Allow User Assembly DownloadsLets researchers download final assemblies from the Assemblies view and study pages.

Neither is restored by Reset to Defaults.

Study Form Builder

/admin/study-form-builder, headed Study Configuration. Four tabs: Study Fields, Per-Sample, Facility Fields, Import / Export. It also autosaves.

Four counters across the top give an at-a-glance summary: fields visible to researchers, facility-only fields, user per-sample fields, and fields hidden by disabled modules.

Study fields are filled once per study — principal investigator, study design, research objectives — while per-sample study fields are collected for every sample the study contains. The MIxS selector normally lives here, which is how a study’s environment checklist is chosen.

With the dynamic-studies module enabled, the sidebar entry changes to Define Studies (/admin/study-definitions) and a study can carry its own questionnaire instead of sharing one global form. Opening the builder for a specific study shows “Editing this study’s own questionnaire — changes apply only to this study.”

Sequencing Run Fields

/admin/sequencing-run-form-builder, headed Sequencing Run Fields. This is the internal questionnaire stored on each run-sample assignment — the row that links one sample to one barcode on one physical sequencing run. Its fields appear in the run plan table and in that table’s Excel import and export, and nowhere else.

Unlike the other two builders it has no tabs and no autosave: edit fields inline, then press Save. Add Field appends a new one; the trash icon removes it. Each row shows the field’s storage name under its label, and badges for Internal (admin-only) and Hidden.

The shipped defaults are an Oxford Nanopore wet-lab set: Barcode, Depletion (host depletion / no depletion / other), Extraction Date, Extraction Method, Analyte (DNA/RNA), Concentration (ng/uL), Post-PCR Concentration (ng/uL), Total Volume (uL), and Run-Specific Notes.

There is also an API-only action that installs the fuller ONT metagenomics/metatranscriptomics preset across both the order form and the run questionnaire, adding only the fields that are missing:

curl -X POST https://your-seqdesk.example.org/api/admin/sequencing-run-form-config/preset \ -H "Cookie: <facility-admin session>"

It answers with how many order fields and run-assignment fields were added.

Removing a field here removes it from the run assignment UI, but values already captured stay in the database — they are simply no longer surfaced. Re-adding a field with the same name brings them back into view.

Import, export and reset

Each builder’s Import / Export tab is how you move a form between instances and how you recover from a bad edit.

Export Configuration

Downloads the current state as JSON. Order exports include the order fields, the fixed sections, and related order settings; study exports include the study fields and sections. Do this before any large change — autosave means there is no other undo.

Import Configuration

Upload a previously exported file. Import replaces the current configuration, after a confirmation dialog. Current exports and older exports containing custom groups are both accepted; legacy groups are mapped into the fixed sections.

Reset to Defaults

Restores the built-in SeqDesk layout after a confirmation that says “Export the current configuration first if you want a backup.” For the order form this restores the default fields and sections; it does not touch post-submission instructions or the data-handling switches.

Applying a form at install time

Exported files can be applied by the installer:

seqdesk -y \ --order-form-settings /absolute/path/order-form.json \ --study-form-settings /absolute/path/study-form.json

For fully unattended deployments the same definitions can be embedded in settings.json under forms.order and forms.study, using the same groups and fields structure that Export Configuration produces:

{ "forms": { "order": { "groups": [ { "id": "group_sequencing", "name": "Sequencing Information", "order": 1 } ], "fields": [ { "id": "field_run_type", "type": "select", "label": "Run Type", "name": "run_type", "groupId": "group_sequencing", "order": 10 } ] }, "study": { "groups": [ { "id": "group_study_info", "name": "Study Information", "order": 0 } ], "fields": [ { "id": "field_study_title", "type": "text", "label": "Study Title", "name": "study_title", "groupId": "group_study_info", "order": 1 } ] } } }

Worked example: a barcoded ONT intake form

Trim what you do not need

On Per-Sequencing Order Fields, hide Instrument Model — the sequencing-tech selector already captures the device — and leave Library Strategy, Source and Selection visible because ENA needs them.

Make the intake unambiguous

Set Number of Samples to required so the sample table is pre-sized, and give Sequencing Order Name a placeholder such as e.g. Soil microbiome study - Batch 1.

Add a per-sample barcode

On Per-Sample, add a barcode field. It is per-sample only by construction, and appears as a column in the sample table.

Add a validated internal id

Still on Per-Sample, add a text field labelled Internal Sample Code with the alphanumeric format preset and a max length of 12. Researchers now get an inline error instead of you cleaning up identifiers later.

Keep facility notes private

On Facility Fields, confirm Internal QC Status and Sample QC Result are visible. They are admin-only, so researchers never see them even though they sit on the same records.

Export

Go to Import / Export and download the configuration. Keep it in your infrastructure repository, and use --order-form-settings when you build the next instance.

Troubleshooting

SymptomCauseFix
A field is configured but invisible to researchersIts module is disabled, or it is marked admin-onlyCheck Modules, and the field’s Admin-only switch
The study builder banner says fields are hidden by modulesSame causeFollow the Manage modules link on the banner
A custom section disappeared after importThe order form has only two fixed sectionsIts fields were mapped into one of them; move them with drag and drop
Changes seem lostThe order and study builders autosave; the run builder does notOn Sequencing Run Fields, press Save
Fields must be an array / Groups must be an arrayA hand-edited JSON import is malformedRe-export a valid file and edit from that
A per-sample field cannot be made order-levelorganism and barcode are per-sample onlyUse a different field type
A mixs, funding, billing or sequencing-tech field cannot be made per-sampleThose types are order-level onlyModel the per-sample part as a separate field
Run-assignment values vanished from the tableThe field was removed from Sequencing Run FieldsRe-add a field with the same name
Reset to Defaults did not restore post-submission instructionsReset covers fields and sections onlyRe-enter them on the Settings tab

See also