Loading
Salesforce now sends email only from verified domains. Read More
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
          Creating a Custom Product Configuration Message

          Creating a Custom Product Configuration Message

          Product compatibility rules, also known as product configuration rules, determine if a product combination is valid. Salesforce includes default product configuration error messages in the Opportunity Manager, Order Manager, Quote Manager, and cart. However, you can create custom messages to provide more useful information to the user.

          For example, consider these sample error messages:

          • Product X requires Product Y

          • Product X excludes Product Y

          • Product X recommends Product Y

          You can create a custom message for each product relationship record. First, you create a user custom message field to display instead of the standard message. Then, you set the CustomRuleMessageFieldName custom setting.

          Note
          Note Requires, excludes, and recommends rules support custom messages because they stay in the cart until the user acts on them. In contrast, auto-add and auto-remove rules don't need user interaction and only show as toast messages, so they don't support custom messages.

          To create a custom product configuration message:

          1. Create a user custom message field.
            • From Setup, in the Quick Find box, enter Objects.

            • Click Objects.

            • Click Product Relationship.

            • In the Custom Fields & Relationships section, click New.

            • Create a new custom field with a Data Type of Text Area. Remember the API name for the field. For more information, see Create Custom Fields in the Salesforce Help.

              The Custom Field Definition Detail section.
          2. Configure the custom field.
            • On the Vlocity CMT Administration tab, click CPQ Configuration Setup.

            • Scroll to CustomRuleMessageFieldName.

            • Click the Action button. Action icon

            • Enter the API name from the field you created in step 1, for example, Message__c.

            • Click Save.

              The CustomRuleMessageFieldName setting.
          3. Expose the new field on the Product Relationships record detail page.
            • On the Product Relationship tab, click a product relationship.

            • Click Edit Layout.

              The Edit Layout button on the Product Relationship page.
            • In the palette, select Fields.

              The Message field in the Layout palette.
            • Drag the field you created in step 1 to the Product Relationships Detail Information section.

              The Product Detail Relationship section of the layout.
            • Click Save.

          4. Enter the custom message.
            • On the Product Relationship tab, click a product relationship.

            • In the custom field, for example, Message, enter the custom message.

            The custom message in the Message field.
          5. Ensure that the active implementation for the ProductValidationInterface is a validation rule implementation.
            • On the Interface Implementations tab, from the View picklist, select All.

            • Click Go!.

            • Click ProductValidationInterface.

            • Ensure that ValidationRulesImplementation or a custom implementation that invokes compatibility rules is active. If it is not, click the appropriate implementation and select Active.

            The ProductValidationInterface with ValidationRulesImplementation set to Active.
           
          Loading
          Salesforce Help | Article