Loading

Enabling the custom field for PPP calculation

Julkaisupäivä: Jun 5, 2026
Edellytykset
Consumer Goods Cloud offline app Penny Perfect Pricing (PPP) enabled Account object custom field (e.g., Distribution_Channel__c) cgcloud__MobilityRelevant field set CG Cloud Modeler installed and configured
Tehtävä

Is there any additional configuration required beyond adding a custom Account field to the cgcloud__MobilityRelevant field set to make it available for PPP calculation in the offline app?

Vaiheet

1. Sync the Field to the Local Database:

Add the custom Account field (e.g., Distribution_Channel__c) to the cgcloud__MobilityRelevant field set on the Account object in Salesforce. This ensures the sync engine downloads the field from Salesforce to the offline app's local SQLite database.

2. Define the Pricing Context and Key Attribute in Salesforce

In the Salesforce org, create a Pricing Context Definition and define a Field Alias for your custom field. Next, create a Key Attribute record. Set the Object to Customer, the Mobility Entity to Customer, and enter a value in the Mobility Attribute field that exactly matches the Field Alias you just defined.

3. Update the Offline Pricing Data Source in CG Cloud Modeler

Open the Consumer Goods Cloud Modeler workspace and check out the offline pricing data source contract named DsComplex_Pricing_sf. Locate the CndCpReadCustomerAttributes query within this contract and add your custom field (Distribution_Channel__c) to the SELECT statement.

4. Map the SQL Alias

In the CndCpReadCustomerAttributes query, you must set the SQL alias for your custom field to exactly match the Field Alias/Mobility Attribute you defined in Step 2. (Example: Account.Distribution_Channel__c AS YourExactAliasName)

5. Build, Validate, and Deploy

After updating the modeler configuration, build the code (sf mdl build) and validate the pricing behavior using the Modeler simulator. Once validated, generate a new Deployment Package and assign it to your users so the updated contracts are pushed to their mobile devices during their next sync.

 
 
 
Knowledge-artikkelin numero

005386003

 
Ladataan
Salesforce Help | Article