Executing JavaScript as business rules
The built-in rules might not be sufficient to address all of your business requirements. You can execute JavaScript code as an action in your business rule. If you need even more flexibility, you can write business rules in custom JavaScript files and execute them as actions.
Use built-in JavaScript as actions
You can execute JavaScript code by selecting Execute a script as an action in the Rules Wizard. The Rules Wizard displays the list of built-in JavaScript, such as:
backup.js
append_copyright.js
backup_and_log.js
The sample backup.js
script creates a backup of a file by copying it to a backup space. This might be required in some business situations. When using a document in your space, try running backup.js
as an action and observe the results.
Extend business rules with custom JavaScript
The Rules Wizard lists all of the JavaScript files that are available in the Company Home > Data Dictionary > Scripts space. You can extend your business...