Interface FormInitApi

All Superinterfaces:
FormInputBuilderApi

public interface FormInitApi extends FormInputBuilderApi
The FormInitApi is exposed to form logics through the form binding during the init phase.

This phase is responsible for defining the form's input parameters and layout structure. The logic returns a list of input definitions (via create* methods inherited from FormInputBuilderApi) and optionally a FormLayout to arrange them visually.

Since:
17.0 - Paloma
  • Method Details

    • layout

      FormLayout layout()
      Returns the FormLayout builder for defining the visual layout structure of the form. Use the returned builder to create containers, rows, and modals, and to arrange input references within them.

      Example:

      
           def layout = form.layout()
      
           layout.addChild(
               layout.createContainer("main")
                   .setHeading("Order Details")
                   .setCollapsible(true)
                   .addChild(
                       layout.createRow("row1")
                           .addChild(input1)
                           .addChild(input2)
                   )
           )
       
      Returns:
      The FormLayout builder instance for this form execution.
      Since:
      17.0 - Paloma