Business Rule to submit catalog item scoped application.
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-22-2024 01:51 PM
Hello,
I am using the below script in Business rule to submit catalog item when a ticket in scoped application is updated.
script:
var cart = new sn_sc.CartJS();
//var cart = new gs.generateGUID(null);
var request = {
'sysparm_id': 'b128f81f8765c61486a10d4acfcc3652',
'sysparm_quantity': '1',
'variables': {
'first_name': 'Abel',
'last_name': 'Tuter'
}
};
var cartDetails1 = cart.addToCart(request);
gs.info(cartDetails1);
var checkoutInfo = cart.checkoutCart();
gs.info(checkoutInfo);
var cartDetails = cart.orderNow(request);
gs.info('See Details :', cartDetails);
But, it is not working... tried using "var cart = new sn_sc.CartJS();" and also tried using "var cart = new gs.generateGUID(null);" still no luck.
Any help is much appreciated.
Thanks,
Ben.
5 REPLIES 5

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-23-2024 08:27 AM
Did you try it without the
cart.orderNow(request);
?
Just wondering since I thought it would work with the one order line.