ctm.createSalesOrderWithAnimations
The method of JS Bridge functionality is intended to provide a transition from CLM presentation to the Sales Order.
Handler
Use a handler function to describe the output format of the query results, e.g., to display the results of operations or method errors for debugging purposes.
-
obj.products contains a list of products where the key is EAN product code, and the value is product quantity.
-
obj.animation contains information about the animation, where the key is a unique animation code, and the value is animation status.
If the transition occurs from a CLM presentation, leave [.apiobject]#obj.animation empty.
var dataStr;
var obj = {};
obj.products = {};
obj.animation = {};
var productEAN = '1234567890',
productQuantity = 10;
obj.products[productEAN] = productQuantity;
var animationCode = '12345',
isAnimationActive = true;
obj.animation[animationCode] = isAnimationActive;
dataStr = JSON.stringify(obj);
ctm.createSalesOrderWithAnimations(dataStr, function(response){
console.log('Result:', response);
})
The results:
{
"success": true,
}