Catalog Variables in Email Subject Line
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-02-2016 01:26 PM
So, to start, I have a notification on the sc_task table set to run whenever a Task is opened assigned to a specific assignment group.
They want a few of the variables that I have set in the catalog item to be present in the SUBJECT LINE.
How do I get my variables (term_name, term_empid, and term_location) to populate in the subject line of these emails?
- Labels:
-
Scripting and Coding
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-02-2016 01:52 PM
You should be able to use ${variables.term_name}, ${variables.term_empid}, etc.
Please mark this post helpful or correct if applicable.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-18-2017 06:29 AM
${current.variables.term_name}
${current.variables.term_empid}
${current.variables.term_location}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-03-2018 11:58 AM
Neither of the listed solutions worked in my client's Istanbul instance. I suspect this is because Variables are associated at the 'Request Item' level, and our notifications are being generated on the 'Service Catalog Task' record.
To access the variable, we must dot-walk to the Request Item.
For a variable named 'req_type', I have verified that this will work in the Subject Line of the SC Task notification:
${request_item.variables.req_type}
There is no need to call 'current' when working with Email variables as they function somewhat differently than other variables in the system.
Of course, we must be sure that a variable with this name exists on *all* items which could potentially trigger this notification. Otherwise, we can add conditions so the notification will only fire for specific Catalog Items.
I hope this is helpful to others who stumble across this page in the future.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-12-2018 02:11 PM
I didn't have to dot walk up to the item if when I created my task I made sure to select them from the slushbucket. If variables weren't present on the task itself then, yes, I would have had to dot walk up. Can't reference something that isn't there.