Enable Variable Editor on Script Generated Tasks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2020 11:03 AM
Hi guys,
I have checked all the corners of the SN community and not able to find the answer. I am trying to get the variable editor to show up on tasks that are being generated by a script. With OOB request management, the RITM has the variable editor enabled by default, and you can enable the formatter on SCTASK for the variable editor to appear. You can then select which tasks display which variables in the workflow.
Well, we have a custom application, and we have been able to get the variable editor to show at the "ritm" level, but the associated tasks are being spawned via a script (depending on what selections are made on the form, one or more tasks will be spawned). I have added the formatter on the custom table that's extended from task, but the variables do not show up. Is there any way to "cascade" the variables from the parent ticket to the spawned tasks?
- Labels:
-
Service Catalog

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-20-2020 04:28 AM
Out of interest, why are you using a script to create and populate the SC_TASK?
I used to use scripting for this but Flow Designer has come on so much, I know exclusively use that from catalog item creation all the way down to Sc_Task population. It has a very nice way of managing what fields populate into the variable editor, from the Request
Here is a sample workflow for a new request item awaiting to deploy in our instance. Simple user request that requires approval and once approved assigns a task to a specific team
Here is an example how I manage variables in flow designer to appear into the variable formatter, from a request
Sorry I know it doesn't specifically answer your question, just thought I'd mention it as I ditched script managing REQ - TASK when I saw Flow Designer really come on and make this sort of setup a 5 minute thing
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-28-2020 08:28 AM
Hey Daniel, thanks for the reply. The main reason we are generating tasks in a scripted manner is because its dependent on the selections.
User selects Application A. Application A has several options listed on a custom table. A task is generated for each option. Same logic for a full list of applications.
This would be fairly difficult to workflow out.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-05-2020 07:24 AM
Ah I see. Sorry can't be more help on the scripting aspect of it