Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

This section is applicable only for the users of Adepta Connect.

Anchor
Process_Flow
Process_Flow
Using Process Flow in a Template

While creating a Process Flow, in the Process Designer, write the following script in the Service exception field under the OnException Scripts tab.  

...

Info
import org.apache.commons.lang.exception.ExceptionUtils;
Throwable rootCause = ExceptionUtils.getRootCause(exception);
String exceptionMessage = null;
if(rootCause == null)
exceptionMessage = exception.getMessage();
else
exceptionMessage = rootCause.getMessage();

context.put("subprocess_code", "ERROR_IN_CHILD_FLOW");
context.put("subprocess_text", exceptionMessage);

Anchor
Process_Flow_Call_Process_Flow
Process_Flow_Call_Process_Flow
Process Flow Calling Another Process Flow

If the Process Flow is further calling another Process Flow, you must create a custom plugin using below JavaScript. After you have created a custom plugin, use it in the Process Flow just before a Call or Spawn activity. In case there are multiple Call or Spawn activities in a Process Flow, you need to add a Custom Plugin before every Call or Spawn activity.

...

RuntimeUtils.abortParentFlow(context,"<<ACTION_NAME>>","<<resultCtxVarName>>");

Process Flow Design

Following are the sample designs of the Process Flow, calling a Transaction through Call or Spawn action:

...