Setup
Conditions and skip rules
Conditions decide what the customer actually meets: which sections are skipped, which questions appear, which of them must be answered and which need a document attached. All of them are built on the Skjemabygger ("form builder") tab in one rule editor, and the two directions that editor runs in — skip against show — are the sharpest edge on the page.
Seksjoner, betingelser og hopp — sections, conditions and skips
Sections (seksjoner), conditions (betingelser) and skips (hopp) share one rule editor. A section's «Hopp over når» ("skip when"), a question's «Avhenger av» ("depends on"), its «Obligatorisk hvis …» and its «Vedlegg kreves hvis …» are all the same tree, with the same operators, the same typed operands and the same ceilings: five levels and 40 leaves per condition. One model means «A eller B» has a single canonical form, and that the editor, the server, the portal and the signed PDF cannot read it differently.
Sections and «Hopp over når»
- Questions can be divided into sections — «Ny seksjon» at the foot of the question list, and every section gets its own «Nytt spørsmål» button — and the form can be presented to the customer as a wizard.
- Every section except the first carries a «Hopp over når» box in the section panel: «Hopp over hele seksjonen når kunden har svart bestemte svar tidligere. Flere regler holder det at ÉN av dem slår til; med «og…»/«ikke» bygger du sammensatte betingelser.»
- The first section cannot be skipped: «Den første seksjonen kan ikke hoppes over — ingen spørsmål besvares før den.»
- A rule may only point at questions the customer answers in earlier sections. Where there are none, the picker says so: «Ingen spørsmål som kunden besvarer i tidligere seksjoner.»
One rule is one sentence
A rule reads as «Svaret» ("the answer") or «Antall svar» ("the number of answers"), then an operator, then one value or two. Which operators are offered follows the question type:
| Track | Operators |
|---|---|
| «Svaret», most types | «er» · «er alle av» · «er ikke» · «er mindre enn» · «er mindre enn eller lik» · «er større enn» · «er større enn eller lik» · «er mellom» · «er besvart» · «er ikke besvart» |
| «Svaret» on a Dato question | The four comparisons read «er før» · «er før eller lik» · «er etter» · «er etter eller lik» instead. A date never reads «mindre enn». |
| «Antall svar» | «er færre enn» · «er høyst» · «er flere enn» · «er minst» · «er mellom» — this is how a file, actor-list or list question gets an "at least 2" condition. |
| Fritekst, Fil-opplasting, Aktørliste answers | «er besvart» and «er ikke besvart», and nothing else. There is no text matching, deliberately. |
A rule with several values carries the note «ett av svarene holder» — or «alle svarene må være valgt» for «er alle av» — and the badge «≥ 1 av verdiene»: «Sammenlikningen treffer når MINST ÉN av svarets verdier oppfyller den — flervalgs- og listesvar sammenliknes verdi for verdi.» An unfinished rule does not apply at all: «Velg minst ett svar — betingelsen gjelder ikke før et svar er valgt.»
Expression trees
Any rule can grow into a tree. «ikke» negates it («Snu betingelsen (IKKE)»), «og…» combines it with AND («Kombiner med OG») and «eller…» with OR («Kombiner med ELLER»). A group carries the selector «alle må stemme (og)» / «én må stemme (eller)», «+ betingelse» ("add a condition to the group"), «Løs opp» ("dissolve the group, keeping its leaves") and «Fjern» ("remove the group and everything in it"). Top-level rules are always joined with «eller» («+ Legg til regel» / «+ Legg til «eller»-regel»), and the expression line reads the whole condition back in Norwegian — groups in parentheses, leaves bound with «OG» and «ELLER», «IKKE» in front of a negation. With no rules at all: «Ingen regler — seksjonen vises alltid.»
- The editor cannot build an invalid tree. A group left with too few leaves is dissolved for you, and the depth is capped at five levels and 40 leaves per section.
- A half-built rule is a local draft. A new rule row starts empty («— velg spørsmål —») and is neither stored nor evaluated until it is complete, so a condition you are in the middle of writing cannot make the form invalid.
- The implicit top-level «eller» list carries no group chrome: no «én må stemme (eller)» selector and no group buttons on the root. Chrome appears only on the groups you built yourself.
Typed operands
Where the type allows it, the value track can be switched from «fast verdi» ("fixed value") or «fast dato» ("fixed date") to «relativ dato» ("relative date") or «terskelverdi» ("threshold value"). «er mellom» has two value tracks, joined by «og».
- «relativ dato» reads as a sentence — «18 | år | før | utsendelsen» — with the units «år», «måneder» and «dager», the direction «før» or «etter», and the anchor «utsendelsen» ("the dispatch") or «besvarelsen» ("the answer"). It is always computed against the round's own timestamps and never against the clock, so a signed answer is judged the same way for ever.
- «terskelverdi» takes an amount from the risk model in token form and is locked to the round's frozen model version.
Conditions in the preview
The preview prints the «Hoppes over når» line for each section with a truth mark per leaf — «SANN», «USANN» or «UKJENT» — from the simulated answers. A skipped section is shown as a stub, «… — Ikke aktuell (hoppet over)», and keeps its number: «Kunden sender inn herfra. Hoppede seksjoner er med i listen, merket «Ikke aktuell».» A relative date that cannot be resolved reads «(uoppløselig på denne runden)».
The preview is a simulation, not a round. It freezes the anchor points when the dialog opens, and it reads threshold amounts from the live model, while a real round uses the model version it froze when it started. The same rule can therefore read differently in the two places, and it is the round's reading that counts.
Conditions on a question
«Avhenger av», «Obligatorisk hvis …» and «Vedlegg kreves hvis …» use that same tree editor, against every question type, with operators, relative dates and threshold values. The visibility field explains itself: «Vis spørsmålet kun når betingelsen mot et tidligere spørsmål er oppfylt — alle spørsmålstyper kan betinges mot, med sammenlikning som på «Hopp over når».» The empty choices are «— vises alltid —» for visibility and «— velg spørsmål —» in a trigger picker, and the expression lines read «Vises når: …» and «Vedlegg kreves når: …».
- Obligatorisk — Frivillig / Alltid / Betinget: «Må besvares kun når betingelsen mot et tidligere spørsmål er oppfylt.»
- Vedlegg kreves — Nei / Alltid / Betinget: «Vedlegg kreves kun når betingelsen mot et tidligere spørsmål — eller dette spørsmålet selv — er oppfylt.», plus «Minst én av svar/vedlegg holder». «(dette spørsmålet)» is offered only where the type has a value comparison; «er besvart» against itself is refused.
A question condition runs the other way from a skip rule. A question is shown only when its condition is definitely true, so under «ikke» an unanswered trigger keeps the question hidden. A skip rule is conservative in the opposite direction: in doubt, it does not skip. That is deliberate — a condition that means "show unless X" must not show on an empty answer.
Grouped trigger pickers
Every picker of a trigger question is hierarchical, on every form, with sections or without: the numbering and the indentation follow the questions' own hierarchy, options are grouped per section («<nr> <tittel>», with «(uten tittel)» as the fallback) and indented as «└ <nummer> <avkortet tekst>», anything outside a section lands under «Øvrige spørsmål», and a long question text is truncated the same way — 64 characters — everywhere. «(dette spørsmålet)» sits ungrouped at the top of the attachment picker.
Duplicating a question or a section
«Dupliser spørsmålet» and «Dupliser seksjonen» are icon buttons. The copy gets a « (kopi)» suffix — on the question text, or on the section title only — lands immediately after the original, and is selected for you. «Minst én av» groups are never copied. An attachment rule that pointed at its own question is repointed at the copy; on a section copy, conditions internal to the section are repointed at the copied counterparts while external targets are kept, and the skip rules come along unchanged.