All the records with empty 'cart_item' field in 'sc_item_option' table and all the records in 'sc_item_option_mtom' table are erased
London Patch 3
This is a known error in the platform and a problem ticket PRB1320482 was created and is fixed
The issue occurs when a custom scripted web service is used to order an item.
In scripted web service, if a custom cart name is passed to the cartJS API and the item is ordered using orderNow() api,
var cart1 = "cart_" + gs.generateGUID() ;
var cart = new sn_sc.CartJS(cart1);
then that web service deletes all the records with empty 'cart_item' field in 'sc_item_option' table and all the records in 'sc_item_option_mtom' table
This issue is logged in the problem ticket PRB1320482 and is fixed.
The workaround for the issue is to add the following details in the Request body,
var cartName = gs.generateGUID();
var itemGuid = gs.generateGUID();
request_body.sysparm_cart_name = cartName;
request_body.sysparm_item_guid = itemGuid;
request_body.sysparm_no_validation = "true";