Behaviours - smbc-digital/form-builder GitHub Wiki

Behaviours

Overview

A behaviour is what tells the form what to do after the form data is submitted. In the page section of a form you can specify none, one, or multiple behaviours.

Structure

behaviours : []

A behaviour is structured in the following way:

BehaviourType: Enumerator Conditions: List BehaviourRelated info such as webservice url and gottoPage

BehaviourType is an enum. The values are given below:

namespace form_builder.Enum
{
    public enum EBehaviourType
    {
        Unknown,
        GoToPage,
        SubmitForm,
        GoToExternalPage,
        SubmitAndPay,
        SubmitAndRedirect,
        SubmitAndEmail,
        SubmitWithoutSubmission
    }
}

If all the conditions are true the behaviour is acted upon. If any conditions are not true, it goes to the next behaviour. There should be a default behaviour with no conditions at the end of the list which is called when none of the conditions of the previous behaviour are true.

⚠️ **GitHub.com Fallback** ⚠️