ProcessData simple form elements - bluesoft-rnd/aperte-workflow-core GitHub Wiki

Simple form elements are used to render one particular form component e.g. input or checkbox field inside the ProcessData widget. They provide no means to influence their relative position , so container form elements must be used for this task.

Common attributes

There are no additional attributes specific only to simple form elements. That means only common attributes are shared.

List of elements

checkbox

Form element used to display a simple two-state switch. It is based on Vaadin CheckBox component.

attributes
Attribute name Type Required Default value Description
defaultSelect Boolean false false If set to true the check box will be selected upon first display of element.
examples
<checkbox caption="Have you read license?" bind="license_accepted"/>

date

Form element used to display and edit date and time value. It is based on Vaadin DateField component. By default this field is set to day resolution.

attributes
Attribute name Type Required Default value Description
format String true The format of the date field.
not-before String false Constrains the date field to accept only dates, that are after not-before date. The date format should match format attribute. One can use current string literal to use current date.
not-after String false Constrains the date field to accept only dates, that are before not-after date. The date format should match format attribute. One can use current string literal to use current date.
showMinutes Boolean false false If set to true the date field resolution will be set to minute resolution.
required Boolean false false If set to true the user will be required to enter a valid date.
examples
<date caption="Birth date" format="yyyy-MM-dd" not-after="current" required="true"/>

input

Form element used to enter short text from keyboard. It is based on Vaadin TextField component.

attributes
Attribute name Type Required Default value Description
secret Boolean false false If set to true the element will be created using PasswordField, making it suitable for confidential data.
maxLength Integer false Allows to limit the maximum number of characters user can type into the element.
regexp String Required if errorKey attribute was used Its value will be used to compile java regular expression and perform check on user input. XML special characters are unescaped.
prompt String false Allows to display textual prompt when the field would otherwise be empty, to prompt the user for input.
errorKey String Required if regexp attribute was used Its value will be used to show error notification if regular expression in regexp attribute is not matching user input.
baseText String false Allows to set default value of field, shown upon first display of element.
requrired Boolean false false If set to true the user will be required to enter text.
examples
<input caption="First name" bind="first_name" width="100%" required="true" 
       prompt="Please enter Your first name"/>
<input caption="Last name" bind="last_name" width="100%" required="true"/>

label

Form element used to display non-editable text. It is based on Vaadin Label component.

attributes
Attribute name Type Required Default value Description
mode Integer false Used to switch Label content mode.
text String true The displayed text of the label. XML special characters are unescaped.
examples
<label text="This is the text"/>

link

Form element used to display simple textual link to other resource. It is based on Vaadin Link component.

attributes
Attribute name Type Required Default value Description
url String true Target location of the link in URL format.
examples
<link caption="Aperte Workflow Homepage" url="http://www.aperteworkflow.org"/>

script

Form element used to embed scripting into the page.

attributes
Attribute name Type Required Default value Description
lang String false
script String false

select

Form element used to select a single item out of predefined set of items. It is based on Vaadin Select component.

elements
Element name Type Required Default value Description
values Item true List of item form elements inside this select.
script Script false Not supported yet.
attributes
Attribute name Type Required Default value Description
defaultSelect Integer false If set its value will be evaluated as index inside the values list, which allows to select the default value on the displayed list.
required Boolean false false If set to true the user will be required to make a valid selection.
examples
<select caption="Preferred size of coffee" required="true" bind="coffee_size">
    <item key="1" value="Small" />
    <item key="2" value="Medium" />
    <item key="5" value="Huge" />
</select>

item

Single item inside select form element values list.

attributes
Attribute name Type Required Default value Description
key String false key is used to distinguish current selection
value String false value is a text presented in the user interface
examples
<select caption="Preferred size of coffee" required="true" bind="coffee_size">
    <item key="1" value="Small" />
    <item key="2" value="Medium" />
    <item key="5" value="Huge" />
</select>

text

Form element used to enter multi-line text from keyboard.

attributes
Attribute name Type Required Default value Description
rich Boolean false false If set to true element is going to be constructed with RichTextArea and support rich text editing.
limit Integer false Allows to limit the maximum number of characters user can type into the element.
visibleLines Integer false Allows to limit the number of text area rows.
required Boolean false false If set to true the user will be required to enter text.
examples
<text caption="Few words about you" bind="info" width="100%" required="true"/>

upload

Form element used to handle file uploading. Finished uploads will be stored as process attachments inside pt_process_instance_attch table.

attributes

none

examples
<upload/>

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