- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-24-2022 02:34 PM
HI All,
I have a strange one and would like if anyone had any suggestions.
Long story short I have a related list in a workspace and a UI action to run on selected items in that list. Problem is the UI action (action assignment) is a server side script. What this means is the script is run for each selected item in the list separately.
What I want is to collect the items and process them together. Think of an email list and I want to send the same email to all selected emails at the same time not one email at a time.
I know in San Diego there is a client script option for action assignments that can give me the sys_id's of the selected items. However this is not there in Rome and we are unable to upgrade yet. This leaves me with the server side script being run for each item individually.....
I was thinking I could raise an event and "flag" the items. Then a script action for that event to check if the event was already raised under the same conditions. If it is not the first event raised with this condition then do nothing. If it is the first event then wait 20 to 30 seconds then collect the "flagged" items and process.
My problem with this is I am not sure how to check by script if an event was triggered.
I also realise if when pressing the action the selected items are processed async it may be hard to tell if another event was first or not.
Any suggestions or workarounds would be much appreciated
Solved! Go to Solution.
- Labels:
-
Scripting and Coding
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-14-2022 08:26 AM
To resolve this issue I ended up doing this in two steps.
1) In the initial UI action in the workspace I flag the items selected.
2) Trigger a business rule that waits 30 seconds then checks for items flagged build the list and then send out the single event to process.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-14-2022 08:26 AM
To resolve this issue I ended up doing this in two steps.
1) In the initial UI action in the workspace I flag the items selected.
2) Trigger a business rule that waits 30 seconds then checks for items flagged build the list and then send out the single event to process.