Service call
Invokes a service that can be triggered by an On load event handler or programmatically.
Appearance
Busy indicator: | Busy icon to show while the service call is executing. {None | Spinner | Refresh | Cog} |
ServiceIndicatorType |
Behavior
Called service: | The service that runs when this view executes. Takes in the Input Value as an argument for the service, and outputs the result as the bound data of this view. |
|
Input value: | The value used as input to the service. If this value changes, the service is automatically invoked with the updated input. | ANY |
Auto run: | Run on start and whenever input data changes | Boolean |
Formula
Input value formula: | String |
Events | ||||||
On Load: |
| |||||
On Invoked: |
| |||||
On Before Result: |
| |||||
On Result: |
| |||||
On Error: |
|
Extends:
Methods:
execute(input)
Executes the attached AJAX service
Name | Type | Default | Description |
input | {ANY} | Input data for the AJAX service (type will depend on the binding type of the AJAX service) |
Inherited
getData()
Returns:
{Object}
Retrieve bound data associated this view/control. Only works for views/controls with bound data.
Example
var dec1 = MyDecimal.getData(); |
getInputData()
Returns:
{ANY}
Returns the input for this service
getLastError()
Returns:
{ServiceError}
Get most recent error thrown
getResult()
Returns:
{ANY}
Returns the result from the attached AJAX service
isAutoRun()
Returns:
{boolean}
Returns the indicator for Auto Run
Inherited
isBound()
Returns:
{boolean}
Indicates bound status of control.
Inherited
isLabelVisible()
Returns:
{boolean}
Checks if control label is visible
Example
var labelVisible = MyView.isLabelVisible(); |
Inherited
isValid()
Returns:
{boolean}
Returns the valid status as last set by the setValid() method.
Example
var valid = MyView.isValid(); |
Inherited
propagateUpValueChange(event)
Returns:
{boolean}
Propagates value change of control up through parent views
Name | Type | Default | Description |
event | {Event} | Value change event (usually an onchange event) |
Example
MyView.propagateUp(event); |
setAutoRun(flag)
Specifies whether this service runs automatically on load and whenever the input value is updated
Name | Type | Default | Description |
flag | {boolean} | Set to true to enable autorun for the service |
setInputData(data)
Specifies the default input for this service
Name | Type | Default | Description |
data | {*} | the input data |
Inherited
setLabelVisible(visible)
Show/hide the label of this view/control
Name | Type | Default | Description |
visible | {boolean} | Label visibility flag (true to show view label, false to hide) |
Example
MyView.setLabelVisible(false); |
Inherited
setViewData(data, createPseudoBinding)
Set/update bound data associated this view/control. Only works for views/controls with bound data.
Note: Should only be used with simple type bindings, or complex type bindings with simple type properties.
Should not be used with bindings that have properties that are lists or compext types. For complex types, set bindings using
the
Note: Should only be used with simple type bindings, or complex type bindings with simple type properties.
Should not be used with bindings that have properties that are lists or compext types. For complex types, set bindings using
the
binding.set
pattern detailed in the Knowlege Center section Binding Data and Configuration OptionsName | Type | Default | Description |
data | {Object} | Value of bound data. The type of this parameter must match the type of the bound data. | |
createPseudoBinding | {boolean} | If set to true, creates a pseudo binding if there is no current binding. |
Example
MyView.setViewData("TEST"); //Updates bound data to the string 'TEST' |
Inherited
triggerFormulaUpdates([phase])
Broadcasts the expression trigger for the specified view
Name | Type | Default | Description |
phase | {int} | bpmext.ui.PHASE_NORMAL | The phase we are currently in |
Example
MyView.triggerFormulaUpdates(); |