BehaviorController component

The BehaviorController component provides reference to mashup calls that are used by the screen behavior code that is mostly called on performing any UI action. For example, on clicking the Next button.

Each controller contains both server-side and client-side components. The mashups that are provided for BehaviorController are called by using JavaScript utility methods on the client. To call a single mashup within the controller, use the isccs.utils.UIUtils.callApi utility method. To call multiple mashups, use the isccs.utils.UIUtils.callApis utility method.

  • To call a single mashup of BehaviorController, pass the following parameters in the isccs.utils.UIUtils.callApi utility method:
    • screen - Screen from which you want to call a mashup.
    • modelInput - Input object to the mashup.
    • mashupRefId - The reference identifier of the mashup that is called.
    • mashupContext - Use the sc.plat.dojo.utils.ControllerUtils.getMashupContext utility method to get mashupContext by passing screen as the argument. If mashupContext is not passed, the isccs.utils.UIUtils.callApi utility method fetches the mashupContext.
  • To call multiple mashups of BehaviorController, pass the following parameters in the isccs.utils.UIUtils.callApis utility method:
    • screen - Screen from which you want to call a mashup.
    • modelInputs - Array of input objects to the mashups that are called.
    • mashupRefIds- The reference identifiers of the mashups that are called.
    • mashupContext - Use the sc.plat.dojo.utils.ControllerUtils.getMashupContext utility method to get mashupContext by passing screen as the argument. If mashupContext is not passed, the isccs.utils.UIUtils.callApis utility method fetches the mashupContext.

For more information about controller utility methods, see the JavaScript documentation.