Usage 

Structure 

[
    {
        title : 'Page Title',
        properties : [
            {
                name : 'Property Name',
                label : 'Property Label',
                description : 'Property Description', //optional, default is NULL
                type : 'Property Type',
                value : 'Property Value', //optional, default is null
                required : 'Mandatory or Not', //optional, 'true' or 'false', default is 'false'
                //… more attributes …
            }, //… more fields …
        ],
        validators : [  //optional
            //… properties custom validators …
        ],
        buttons : [  //optional
            //… custom properties page buttons …
        ]
    }, //… more properties page …
]

Sample Look and Feel

Field Types

Check Box

Code Editor

Combine Grid

Element Select Box

Fixed Row Grid

rows : [
    {label : 'Username', required: 'true'},
    {label : 'Status'},
    {label : 'Message'},
    {label : 'Date'}
]

 

Grid

Header

Hidden Field

HTML Editor

Label

Multi Select Box

Password Field

Radio Button

Readonly Text Field

Select Box

Text Area

Text Field

 

Dependency Field Attributes

Options Field Attributes

options : Optional, an array of JSON object with 'value' and 'label' attributes.

options : [
    {value: 'value1', label : 'Value 1'},
    {value: 'value2', label : 'Value 2'},
    {value: 'value3', label : 'Value 3'}
]

options_ajax : Optional, a URL which will return an array of JSON object with 'value' and 'label' attributes.

options_ajax : '[CONTEXT_PATH]/web/json/console/app[APP_PATH]/datalist/options'

options_ajax_on_change : Optional, name of a property field. Used together with 'options_ajax' attribute. The field name and its value will passed as HTTP request parameter to the URL.

options_ajax_on_change : 'type'
options_ajax : '[CONTEXT_PATH]/web/json/app[APP_PATH]/plugin/org.joget.plugin.enterprise.SamplePlugin/service?action=getJson'

options_callback : Optional, a javascript function name. All attributes in the field will passed as a single JSON object parameter to this function. The function should return an array of JSON object with 'value' and 'label' attributes.

options_callback: 'DatalistBuilder.getColumnOptions'

options_script : Optional, a string of javascript which will return an array of JSON object with 'value' and 'label' attributes.

options_script: 'var tempArray = [{\'label\':\'\',\'value\':\'\'}]; 
for(ee in DatalistBuilder.availableColumns){ var temp = {
\'label\' : UI.escapeHTML(DatalistBuilder.availableColumns[ee].label),
\'value\' : DatalistBuilder.availableColumns[ee].id}; 
tempArray.push(temp);}tempArray;'

Built-in JSON API for 'options_ajax' 

Built-in Javascript Function for 'options_callback'

Grid Related Attributes

Validator Types

AJAX

Page Button


Variable

[CONTEXT_PATH]

[APP_PATH]

Retrieve Properties Value in Plugin

Single Value Field

Multi Values Field

Combine Grid Field

Grid Field

Element Select Box