Apply Promotion Doest Not Add Default Products In Headless Mode

(Doc ID 1913404.1)

Last updated on MARCH 02, 2017

Applies to:

Siebel CRM - Version [21233] and later
Information in this document applies to any platform.


On : [21233] version, Order Management




Issue is customer is trying to create promotion products using headless mode. In this case, they are not able to see the default products defined at 

the product level.


Customer is trying to create promotion products using headless mode. In this case, they are not able to see the default products defined at the 
product level 


Applying promotion should add default products defined at promotions as well as product level. 

Step 1: Prepared the  following product structure: 

Product Name    Default 
CP                              1 
SP1                            1 
SP2                            1 
SP3                             0 
SP4                             0 

Create Promotion ¿Aditya Promo¿ default as 1 
Add CP to Promotion Aditya Promo Default as 1 
Drilldown on CP and define SP3 and SP4 default cardinality as 1 
Identify the promotion id: 1-89HS 

Now Go to Quote-->Create New Quote and identify the quote id: i.e 1-8APU 

I tried to simulate the following business Service with below code: 

Step 2: Crete script for simulation 
Go to Administration Business Service 
Create New Script: "ApplyPromotionCardinilaty" 
Bottom Business Service Script create two following records: 
Program Language: eScript 
Copy the following script in script area: 

function Service_PreInvokeMethod (MethodName, Inputs, Outputs) 

if (MethodName == 'CreatePromotion') 
return (CancelOperation); 


return (ContinueOperation); 

Name = (declarations) 
Program Language: eScript 

Copy the following script in script area: 

function CreatePromotion(Inputs,Outputs) 

var sQuoteId  = Inputs.GetProperty("QuoteId"); 
  var sProdId  = Inputs.GetProperty("ProductId"); 
  var QuoteBO  = TheApplication().GetBusObject("Quote"); 
  var OliBC   = QuoteBO.GetBusComp("Quote Item"); 
  var QuoteBC  = QuoteBO.GetBusComp("Quote"); 
  var bcProduct  = ""; 
  var svcInputs  = TheApplication().NewPropertySet(); 
  var svcOutputs  = TheApplication().NewPropertySet(); 
  //var errorMess  = "OK"; 
  var sAssetIntId = ""; 
   var orderExists = FirstRecord(); 
   if (orderExists) 


     bcProduct = GetPicklistBusComp("Product"); 
      SetSearchSpec("Id", sProdId); 
      if (FirstRecord()) 

     sAssetIntId = GetFieldValue("Id"); 

  var svcPromo = TheApplication().GetService("ISS Promotion Management 
  var svcHeadlessConfServ = TheApplication().GetService("Headless 
Configuration Service"); 
   SetProperty("Active Document Id", sQuoteId); 
   SetProperty("Prod Prom Id", sProdId); 
   SetProperty("Qty", 1); 
   SetProperty("Prod Prom Instance Id",sAssetIntId); 
   SetProperty("Target Document", "Quote"); 

  svcPromo.InvokeMethod("ApplyPromotion", svcInputs, svcOutputs); 
   SetProperty("Promotion Automatch", "Min Max Cardinality"); 
   SetProperty("Document Id", sQuoteId); 
   SetProperty("Document Type", "Quote"); 
   SetProperty("Integration Object", "SIS OM Quote"); 
   SetProperty("Sync", "Y"); 
  svcHeadlessConfServ.InvokeMethod("Apply Promotion Defaults", svcInputs, 


Step 3: 
Go to Methods: Create New Record name as "ApplyPromotionCardinilaty" 
Crete the method: CreatePromotion 

Crete following Method Arguments: 

1. Name = ProductId, 
Type: Input / Output 
Storage Type: Property 

2. Name =QuoteId 
Type: Input / Output 
Storage Type: Property 

Step 4: 
Go to simulator Cretae new record 

ServiceName: ApplyPromotionCardinilaty 
Method: 1 
Input Arguments: 

PropertyName: ProductId 
PropertyValue: 1-89HS 

PropertyName : QuoteId 
PropertyValue: 1-8APU 

Simulated the Service: 

Results: Promotion created with following line items in Quote: 

Promotion: Aditya Promo with Qty as 1 
CP  Qty as 1 
SP3 Qty as 1 
SP4 Qty as 1 
Actual Result: SP1 and SP2 were not created, only SP3 and SP4 are getting 

Expected Result: Along with Promotion and CP, SP1 and SP2,SP3 and SP4 should get created. 

The issue has the following business impact:
Due to this issue, users cannot  do Apply Promotion when called through Workflow


Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms