Import Variables into Description Field / RITM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-19-2014 07:36 AM
What's the best way to import the variables from ESS Service Catalog offerings into the Description field as text in REQ's/RITM's?
Several of our request have numerous variables, and I'm finding they look chunky and crowded when populating in the 'Variables' field in the REQ/RITM, so I'm wondering the way to just take this variable data from the service catalog offerings and import it as text into the 'Description' field.
Since we use Short Description/Description in Incident anyways, this will help tech's make the transition because the form will be more like what they're used to seeing.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-22-2017 06:13 AM
Hi Brad, this link has been suggested to help me on help ive asked for... How to copy data into the TASK from the RITM ... However being a bit of a Noob. your suggestion above is missing information. Could you advise please...
1. have I got the correct table?
2. What is the condition
3. Why have I got an 'error'...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-01-2018 09:49 PM
Hi Steven,
Not sure if you still need it but for the community I'll try answer your question.
You just need to declare the key variable.
for (var key in current.variables) {
}
Your other questions:
Yes, sc_req_item is the correct table if you want to populate the "Description" field on the Requested Items
Condition only has to be populated if you don't want it to run every time. You can also use the filter under the "When to Run" tab to do a similar thing.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-24-2014 02:57 PM
Thanks Brad -
This is helpful, however it seems like it's doing 2 things I wouldn't want:
- I see a 'null:' sometimes, and
- It seems to take the variables out of order in the description
See attached screenshot and let me know if you pickup on it. Notice the Toner and For Printer variables are interchanged in the description vs one sequential variable list in the description. Possible to do any kind of omit if null for the other variables? Thx.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-24-2014 11:21 PM
check before:
v.getDisplayValue() is null or not null.
if(!JSUtil.nil(v.getDisplayValue())
{
not null, add to description
}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-25-2014 12:19 PM
Thanks Chandan - but I'm not sure what you mean by check before - where are you suggesting adding this code to what Brad already added?