Custom Form Window Functions
Last updated
Was this helpful?
Last updated
Was this helpful?
Was this helpful?
This guide describes the functions available in the Pepperi JS Client Side API that manage the user experience of Custom Web Forms within Workflows. These functions control the closing, canceling, and saving of forms, with notes on deprecated usage.
Description: Closes the Custom Web Form window without affecting the Workflow status.
Use Case: Use this to exit the form when no changes need to be preserved or canceled.
Syntax:
window.pepperiApp.onClose();
Description: Closes the Custom Web Form window and cancels the Workflow, reverting to the previous status.
Use Case: Ideal for discarding changes and undoing the current Workflow step.
Syntax:
window.pepperiApp.onCancel();
Description: Closes the Custom Web Form window and saves changes applied to the Workflow object (deprecated).
Use Case: Use this only if relying on the deprecated Workflow object to persist modifications.
Syntax:
window.pepperiApp.onSaveAndClose();
Note: The Workflow object is deprecated; consider modern alternatives for new implementations.