- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-04-2022 10:14 PM
i have been trying to generate Request ticket from Schedule Jobs using the following script
var cartId = GlideGuid.generate(null);
var cart = new Cart(cartId);
//gives sys_id of catalog item
var item = cart.addItem('5104596487ed0910d0d4ca27cebb35fc', 1);
item.setVariable("requested_for", gs.getUserID());
var rc = cart.placeOrder();
everything is works fine but not displaying the Requested_for value by default. Please help
Solved! Go to Solution.
- Labels:
-
Multiple Versions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-05-2022 12:40 AM
I have written this in a Scheduled Job as you need, but in case you need to write or use this in an Server side function you can do it as well :
Scheduled Job screenshot for reference as well:
Hope this helps. Please mark the answer as correct/helpful based on impact.
Regards,
Shloke
Regards,
Shloke
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-08-2022 11:00 AM
Hi bro, its not working (not displaying the requested for )
but when I use the Run as field it requested for is displaying but no matter who triggers it . it just shows only one name (the same name).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-05-2022 01:16 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-05-2022 01:16 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-05-2022 01:23 AM
bro its working thanks