You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A scheduled job script to deactivate and reactivate forms automatically during a maintenance window.
4
+
5
+
## Description
6
+
7
+
This script can be added to a scheduled job to deactivate and reactivate catalog items and/or record producers. An example of a use case is where maintenance is being performed which will involve a system outage so certain forms that might rely on an integration with that system need to be disabled during the maintenance window.
8
+
9
+
## Getting Started
10
+
11
+
### Dependencies
12
+
13
+
* None
14
+
15
+
### Execution
16
+
17
+
1. Create a scheduled job that automatically runs a script of your choosing.
18
+
2. Configure the scheduled job to run at the relevant time (see image for example).
19
+
3. Copy the script from deactivate-reactivate-cat-item.js into the 'Run this script' field.
20
+
4. Modify the variables as required:
21
+
* Add or remove variables to capture all of the catalog items that need to be deactivated/reactivated.
22
+
* Ensure the sys_id of the catalog item is set as the variable value.
23
+
5. Update the array list on line 8 to include the variables you want to use.
24
+
6. Set the value of the active flag on line 11 to 'false' to deactivate the catalog item or 'true' to activate the catalog item.
25
+
7. Save the scheduled job and it will run once the trigger condition is met.
26
+
27
+
### Additional Information
28
+
If you are setting a deactivate scheduled job for a maintenance window, make sure you create a second scheduled job to reactivate the catalog items once the maintenance window is closed.
0 commit comments