English
approval.agree.render.before
About 262 wordsLess than 1 minute
2025-12-16
Description: this event is called before rendering approval agree
This event is used to perform extra actions before rendering approval agree, including but not limited to: 1. Retrieving workflow data 2. Determining whether the task can be completed directly 3. Completing the task directly 4. Forcing an edit-content popup/page 5. Customizing workflow layout/form secondary action buttons
Parameters
| Parameter | Description | Type |
|---|---|---|
| getData | Retrieves workflow data (Example) | Function |
| canDirectCompleteTask | Determines whether the task can be completed directly (Example) | Function |
| directCompleteTask | Completes the task directly (Example) | Function |
| forceShowEditForm | Forces the edit-content popup/page to be shown (Example) | Function |
| customFormButtons | Customizes workflow layout/form secondary action buttons (Example) | Function |
Examples
1. getData
Used to retrieve workflow data, which can then be used to distinguish different approval flows and apply different business logic.
2. canDirectCompleteTask
Used to determine whether the task can be completed directly.
3. directCompleteTask
Completes the task directly without showing the approval popup.
4. forceShowEditForm
Forces the edit-content popup/page to be shown even when the standard behavior would skip it.
5. customFormButtons
Customizes the naming, visibility, and ordering of workflow layout/form secondary action buttons.
Notes
- The button array in the input parameters does not include the
Cancelaction button. - Returned button configurations must be customized based on the buttons in the input array.
- If a button does not exist in the returned array, that button will be hidden.
- The display order of buttons is completely determined by the order in the returned array.
