Skip to main content

Cart Rules, Tags and Display

A "tag" typically refers to a label or identifier attached to a product for various purposes. Tags are used to categorize, organize, and manage products, making it easier for users to search for, filter, and find specific items.

In the latest upgrade to the OneCPQ package, a default enhancement has been implemented. Now, as a standard feature, when users add a product to the cart, they will automatically notice a newly introduced element a tag icon displayed at the end of the product.

image.png

Upon clicking the tag icon, a text pop-up will appear, prompting the user to input a tag(s). Users are required to enter the desired tag and subsequently click the designated right icon to confirm their input.

image.png

When users type their input and press the Enter key, each entered tag is distinctly displayed. This deliberate design choice aims to enhance user visibility and facilitate more efficient comprehension during the text entry process.

image.png

image.png

Upon adding a tag to a product and saving the changes, the system dynamically displays the available tags in the top section of the product details page. This intuitive design not only provides immediate visibility to the assigned tags but also empowers users to efficiently filter products based on these tags.

image.png

Cart Rule

The Cart Rule feature in our system serves as a dynamic tool for determining specific actions when items are added to the cart, based on predefined conditions.

When creating a new Cart Rule, there are two fields: "Constraint" and "Event."

image.png

Constraint Field The "Constraint" field is where you define the conditions that must be met for the Cart Rule to come into effect. This field serves as the trigger for the rule.

Example : Specify conditions related to the contents of the cart, such as the total quantity or discount.

image.png

Event Field - The "Event" field determines when the actions associated with the Cart Rule will start taking effect.

Example : The rule enforced as soon as the product is added to the cart.image.png

The three types of actions in the context of the Event:

  1. Init (Initialization) : The "Init" event is triggered when a product is added to the cart for the first time.
  2. Load : The "Load" event is triggered when the cart is loaded including cart pagination.
  3. Change : The "Change" event is triggered whenever the product in the cart is updated.

Cart Rule Actions:

In the context of cart rules, actions represent the specific operations or changes that are executed when the conditions defined by the rule are met.

When creating a new Cart Rule, there are two fields: "Where" , "What" and "Type".

  1. Where : The "Where" field specifies the precise location or context where changes are to be applied.
  2. What : It provides a detailed description of the modifications. What field should always be entered in single quotes.
  3. Type : It could refer to the specific kind or category of action that is being taken. 
  4. Result : The 'Result' field is utilized to trigger an action based on a specified condition. When the condition is met, the checkbox in the 'Result' field is set to 'checked'; conversely, when the condition is not met, the checkbox remains unchecked.

In cart rule action, there are various types of actions.

Change Column Label :  The alteration of field labels within the cart. This functionality allows for a refined customization of the display names associated with specific fields, enhancing the user interface and providing a more tailored and professional appearance.

        Example : The default label "unit price" has been altered to "Sale Price." in the cart

image.png

Hide Column : The "Hide Column" functionality serves to dynamically obscure a designated column within the cart interface once specific pre-defined conditions are met. 

        Example : The Recurring Unit Price column needs to hide in the cart.

image.png

Show Column : The "Show Column" functionality facilitates the display of a designated column within the cart when specific conditions are met.

        Example : The "Term" column in the cart will be displayed when the quantity exceeds 10.

image.png

Apply Cell Style and Apply Row Style : Implementing conditional color changes in the cart based on user visibility adds a valuable layer of customization and enhances the user experience. By dynamically altering the color of cells or rows, users can easily discern different views or conditions, contributing to improved visual clarity.

        Example :  When Quantity is greater than 25, the Total Price column's cell style should be altered, and the entire row should be colored pink.

image.png

image.png

Disable Cell and Enable Cell :  The functionalities of "Disable Cell" and "Enable Cell" are employed when specific conditions are met, and it is necessary to restrict or grant access to certain columns based on those conditions.

Example : When the Quantity surpasses 25, the Unit Price column transitions to a non-editable state, restricting any user                          attempts to modify its content. Conversely, when the Quantity is 25 or below, the Unit Price column remains                              editable, allowing users to modify its content as needed

image.png

image.png

image.png

With these functionalities, the user needs to interact with the cell (e.g., click or focus on it) to determine whether it is editable or not.

Lock Cell and Unlock Cell :  The terms "Lock Cell" and "Unlock Cell" more explicitly convey the editability status of the cell. A locked cell is immediately visually apparent as read-only without requiring the user to interact with it.

Example :  When Quantity is greater than 25, the Unit Price column's cell should be read-only field. conversely, it should remain editable when the quantity is equal to or less than 25.

image.png

image.png

Hide Cell and Show Cell :  The terms "Hide Cell" and "Show Cell" more explicitly convey the visibility status of the cell.  

Change Cell Control : 

Format Cell : 

Hide Action and Show Action : The strategic implementation of "Hide Action" and "Show Action" in a cart interface involves dynamically managing the visibility of specific actions, such as Delete, Sync, and Empty, based on cart rules.

Example : when the quantity surpasses 25, the "Clone" action is to be concealed from the user; conversely, it should remain accessible for cloning the product when the quantity is equal to or less than 25.

image.png

image.png

image.png

Change Action Label : The objective of this feature is to provide the capability to dynamically alter the label of a specific action within the shopping cart based on evolving business requirements. This enhancement aims to offer flexibility in adapting the user interface to changing business needs seamlessly.

Example : To dynamically alter the label of the "Clone" action within the cart based on the quantity parameter. Specifically, when the quantity surpasses 25, the label should change to "Product Clone."

image.png

image.png

Show Error, Show Warning and Show Info : The objective of this feature is to dynamically display error messages to particular field in when specific conditions are met within the cart. This enhancement aims to provide clear and actionable message to users, facilitating a more informed and responsive user experience.

Example :  To notify users when the quantity in the cart surpasses a predefined threshold, indicating that the opportunity needs to undergo an approval process. This enhancement aims to provide clear communication to users about the necessary approval step for high quantities.

image.png

image.png

Hide All Tag Tabs and Show All Tag Tabs: Hides or shows all tags that are displayed in the form of tabs above the cart.

Hide Tag Tabs and Show Tag Tabs: Hides or shows tags specified in the condition.

Hide Tag Icon and Show Tag Icon: Hides or shows the tag icon in each line item of the Cart based on the condition of the rule.