Loading
Get Started with Communications, Media, and Energy & Utilities (CME)...
Table of Contents
Select Filters

          No results
          No results
          Here are some search tips

          Check the spelling of your keywords.
          Use more general search terms.
          Select fewer filters to broaden your search.

          Search all of Salesforce Help
          Penalty Rules for Promotions

          Penalty Rules for Promotions

          To apply a penalty amount when a promotion is canceled in the Industries Cart, use context rules with the rule type, Penalty. Penalty rules apply only when promotions are canceled during a move, add, change, or delete operation or in asset-based orders. Penalty rules are applied when one or more penalty conditions are met.

          Prerequisites to Set Up Org for Penalty Rules

          Verify that the following settings are configured in your organization before setting up penalty rules. See Configure Your Org to Use Context Rules for details on how to configure the following settings.

          • Context rules are enabled.

          • Cache is enabled.

          • Trial storage allocation for the platform cache, named CPQ Partition, is set.

          • CtxRulesProductsOpenImplementation interface implementation is activated.

          • If you use the function condition in the rule, then make sure that an apex class is deployed and the function definition in Custom Metadata types is set.

          Set Up Penalty Rules

          Penalty rules are created in the Vlocity Product console using the same context rule components as qualification context rules.

          1. Create a penalty rule.

            See Creating a Penalty Rule.

            1. Don’t include spaces in the Context Dimension name, Rule Condition Code, and Rule Code.

            2. Don’t include spaces, "-", and "_" in the Function name.

            3. When defining a custom expression, use spaces to delimit each element. For example: ( Rule1Code OR Rule2Code ) AND Rule3Code

              1. Use one space between parenthesis and code.

              2. Match code exactly because code is case-sensitive.

              3. UseAND and OR exactly.

              4. Don’t use unsupported characters: &&, ||, and, or, And, Or.

            4. Set up the Data Type of Context Dimension correctly and use text instead of string.

            5. Ensure that condition weight in dimension is <= 30.

            6. Ensure that the Context Dimension name isn’t a function name.

            7. To get context from a field from custom object, such as, ContractTerm field from the vlocity_cmt__ContractId__c in Asset Object, use __r instead of __c (Asset.ContractId__r.ContractTerm).

          2. Create a rule condition for the penalty rule.

            See Creating a New Rule with Simple Condition.

            Note
            Note

            Penalty is applied when the specified condition is true and the Fail Level = Hard Fail.

            Here’s an example.

            Rule condition for a penalty rule
          3. Create a pricing element charge.

            See Create a Pricing Element Charge or Adjustment in the Pricing Designer.

            Here’s an example of a pricing element called Penalty20.

            Pricing element charge
          4. Create a context action.

            See Create Context Actions.

            Here’s an example of a context action called Penalty20.

            context action
          5. Create a rule set using these values.

            See also Create a rule set.

            Enter these values:

            1. Rule Type: Penalty

            2. Rule Purpose: Eligibility

            3. Expression Mode: If Else If or If

            4. Header Rule: optional

          6. Add a child penalty rule. In the child penalty rule,

            1. Set Action Taken to Policy Action.

            2. Select the Context Action that you created earlier.

              Child penalty rule

              You can add multiple rules with different actions. For example:

              If customer segment = B2B, apply penalty20,

              Else if customer segment = B2C, apply penalty10,

              Else (Always true rule), apply penalty30.

          7. Apply the penalty rule set to a promotion.

            See Penalty Rules - Assigning to a Promotion.

          Cancel Promotions

          See how to cancel a promotion in Industries Cart.

          1. Go to the Account record detail -> Assets page.
          2. Select the asset whose promotion you want to cancel.

          3. Click Change to Order.
          4. From the Promotions tab, select and cancel the relevant promotion.

            Cancel a promotion
          5. Enter a cancel date and a reason for cancellation, and then click Evaluate.

            Reason for canceling a promotion

            If the cancellation initiates a penalty rule, the Cancel Promotion dialog shows you the penalty amount that’s levied if you cancel the promotion. You can cancel the promotion or keep it.

            Penalty rule is triggered

            If you choose to cancel, the promotion status changes to Disconnect.

            Promotion is disconnected

            The Order Pricing object (vlocity_cmt__OrderPriceAdjustment__c) keeps a record of the levied penalty and any reversed promotional pricing adjustments.

          6. To see the penalty applied to an order, check Order Pricing Detail.

            Penalty under the Order Pricing object
           
          Loading
          Salesforce Help | Article