- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-19-2018 01:30 AM
Hi Experts,
I have designed a workflow for ordering Software. The process is that it opens a request item then an RITM.
I am facing a problem that whenever I request for a software, it opens two workflows for a service Request, one is oob workflow Service Catalog Request, and my designed workflow SC-Software Request wf. As a result it automatically sets the Approval value as Approved due to the oob process Runs.
I am unable to separate it. I want only my designed SC-Software Request wf to Run. The only method is to quote a price of the software I think which If I increase more than $1000, then it will not set the value automatically to be approved. Is there a way I only want my workflow to Run for this Request.
Regards,
Raju Singh
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-22-2018 03:19 AM
Use below
var title = '';
var desc = '';
var ritem = new GlideRecord('sc_req_item');
ritem.addQuery('request',current.sys_id);
ritem.query();
while (ritem.next())
{
if (title=='')
{
title = ritem.cat_item.getDisplayValue();
desc = ritem.cat_item.category.getDisplayValue();
}
else
title = title + ','+ritem.cat_item.getDisplayValue();
desc = desc+','+ritem.cat_item.category.getDisplayValue();
}
current.short_description = title;
current.description = desc;
Please mark this response as correct or helpful if it assisted you with your question.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-22-2018 12:32 AM
Added one more line to correct it. Business rule on request on insert and on update
var title = '';
var ritem = new GlideRecord('sc_req_item');
ritem.addQuery('request',current.sys_id);
ritem.query();
while (ritem.next())
{
if (title=='')
{
title = ritem.cat_item.getDisplayValue();
}
else
title = title + ','+ritem.cat_item.getDisplayValue();
}
current.short_description = title;
Please mark this response as correct or helpful if it assisted you with your question.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-22-2018 12:46 AM
No, Sanjiv
Still it doesnt work.. The short description doesnt get populated yet even after putting this code.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-22-2018 12:57 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-22-2018 02:05 AM
I am not sure, when I put the same query... Why do I get the short description as 'title'
I do not get the catalog item name at all...
Here is the screen shot of the code which is exactly your code.
Here is the result in the Service Request
can I get the name of the category like the the service catalog category is 'Software Request'

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-22-2018 02:40 AM
Correct line 19
current.short_description = title;
instead of current.short_description = 'title'; ->this is wrong
Please mark this response as correct or helpful if it assisted you with your question.