Versions Compared

Key

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

...

The Code option takes you to the Implemented Class where you can make any additional ABAP code changes that you may require.
 The methods can be redefined by clicking on .https://iqxbusiness.atlassian.net/browse/FAB-1829



Method NamePurpose
Set Model Data Each Time Form is loaded

Allows you to programmatically determine and set default values for fields within your data model.   

Parameter I_FIRST_TIME will be set to X if this is the first time the form is loaded.  It will be blank on subsequent loads such as when the form has been submitted and the approver has opened it for review.

Perform Action at any TimeProvides a way to implement logic that can be executed at any time from within the application.  These actions can be called from button click events (FabAction) or directly from JavaScript.
Validate Data before SaveAllows for backend validation of data before the data is saved and the next workflow step is executed.
Enhance Data Before SaveProvides a method that can enhance data during the save process.  This method can be used to determine and populate calculated fields.
Perform Actions when Status Changes on Save

This method is called after the Validate and Enhance methods and can be used to execute specific functionality when the workflow steps change.

Parameters I_CURRENT_STATUS and I_ACTION will be populated with the action that was performed and the new status.

Changing the status can be achieved through the C_STATUS_REDETERMINED, C_NEW_STATUS and C_NEW_APPROVAL_LEVEL parameters.

Check and Send NotificationIf email or other notification is required when the workflow enters a specific stage (e.g. Approvals), this method can be used to send the email or trigger the notification.  For each step in the workflow configuration, there is a Email Required checkbox.  This allows for emails to be turned on and off through configuration rather than making code changes.  In the method, the base class method should be called (call method super->check_and_send_notification) which will return a boolean parameter e_email_to_be_sent.  The value of this parameter is set based on the Email Required checkbox and the code should check whether this is set to true before sending the notifications.
Determine Approvers when Data is SavedIf the approvers are being dynamically determined then this method is called to allow the developer to populate the CT_APPROVERS parameter with the appropriate approvers.
Determine Approvers for RolesUsed to determine which approvers will be associated with each role when using the Enhanced Workflow with custom roles.
Evaluate Task/Outcome RequirementsAllows for the determination of Enhanced Workflow requirements through ABAP code.  The method will be passed the requirement ID as configured in the workflow and provides the ability for the developer to evaluate whether that requirement is true or false.

Determine Approvers when SAP Workflow is Used

When using SAP Workflow and the approvers are being dynamically determined, this method is called to allow the developer to populate the CT_APPROVERS parameter with the appropriate approvers.
Handle Escalations

The logic for handling escalation triggers is done by implementing method ESCALATION_PROCESS.

New approver(s) can also be determined based on the escalation level reached. Methods DETERMINE_APPROVERS_ON_SAVE or DETERMINE_APPROVERS_WORKFLOW can be used to determine and set these approvers based on the escalation level (import parameter I_ESCALATION_LEVEL).

Program /IQX/ESCALATIONS_PROCESS need to be scheduled to run periodically as a background job with a variant that includes the Form Name. It is recommended to schedule the job to run every 15 minutes.

Format Attributes in WorklistThis method allows the developer to select which attributes should be displayed in the MyForms application.  This provides a way for users to easily distinguish between different requests in MyForms by using unique values (e.g. Description, Request Type, Cost) from the data model.
Format Icon in WorklistThe icon for the application shown in the MyForms app can be changed through this parameter however it is strongly recommended that the developer select the icon from the Properties dialog to provide the optimal performance.
Set Search Fields in Worklist

The Set Search Fields in Worklist method (FORMAT_MY_FORMS_SEARCH_FIELDS) is used to configure which fields (up to 5) that can be stored at the header level so that searching and filtering can be performed.

Currently this stores to the header table for manual retrieval however later versions of My Forms will provide searching and filtering capabilities based on these fields.

...