Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Downgrade docu #336

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions changelog/2024/2024-10-30-changelog.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
title: 'Added skuless product selection in Promotions Builder'
date: '2024-10-30'
tags: ['Commerce Manager', 'Promotions Builder']
hide_blog_post_date: false
---

**MINOR** We have introduced the ability to select SKU-less product bundles in the promotion builder's product selector. For more information, see [Creating a Cart Items Condition in Commerce Manager](/docs/commerce-manager/promotions-builder/creating-a-promotion-in-promotions-builder#creating-a-cart-items-condition).

14 changes: 14 additions & 0 deletions changelog/2024/2024-10-31-changelog.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
title: '"Deep linking" in Commerce Manager'
date: '2024-10-31'
tags: ['Commerce Manager', 'Core']
hide_blog_post_date: false
---

**MAJOR** We have introduced the ability to "deep link" in Commerce Manager

We have improved the way we handle organization and store switching. We now have the organization and/or store id stored the url, so you can easily share the url with others and they will be taken to the same organization and store you were in when you copied the url.

You can now have multiple tabs/windows open in your browser and switch between organizations and stores without having to worry about losing your state.

This does mean any bookmarks you have for say https://euwest.cm.elasticpath.com/products will no longer work as expected because it doesn't have the store/organization id in the url. You should instead be redirected to the store selection page and once you select the store you will be taken to the correct page.
13 changes: 13 additions & 0 deletions changelog/2024/2024-11-05-changelog.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
---
title: 'Added Flows support for Promotions Builder'
date: '2024-11-05'
tags: ['Commerce Manager', 'Promotions Builder']
hide_blog_post_date: false
---

**MINOR** We have introduced Flows support for Promotions Builder that allows users to create custom fields for promotions. For example, you can create cusom fields to [display custom promotion terms and conditions](guides/How-To/promotions-builder/use-flows-with-promo-builder.mdx) messaging in the storefront.

For API, see [The Promotions Builder Custom Fields API](/docs/promotions-builder/promotions-builder-api/promotions-builder-api-overview#the-promotions-builder-custom-fields).

For Commerce Manager, see [Editing custom fields in a promotion builder](/docs/commerce-manager/promotions-builder/creating-a-promotion-in-promotions-builder#editing-custom-fields-in-a-promotion)

Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ sidebar_position: 1
1. Select the end date in the **End Date** field.
1. Enter the priority number in the **Assign a priority** field. This field determines the order of the stackable promotions that can be applied simultaneously. Each promotion must have a unique priority number. If you assign a priority number that is already in use by another promotion, you will receive an error message.

This step is optional. If a priority is not assigned, promotions will be applied in the order of their creation dates, with the newest promotions applied first and discounted prices calculated against any previously-discounted item prices.
This step is optional. If a priority is not assigned, promotions will be applied in the order of their creation dates, with the newest promotions applied first and discounted prices calculated against any previously-discounted item prices.
1. Select the **Enabled** toggle to activate the promotion. It is disabled by default.
1. Select the **Stackable** toggle to allow multiple promotions to be stacked. This option is disabled by default and controls whether a promotion can be stacked with others. If this toggle is not enabled, no other promotion can stack on top. The promotion with the highest priority will take precedence. See [Stacking and Prioritizing](/docs/commerce-manager/promotions-builder/#stacking-and-prioritizing-multiple-promotions)
1. (Optional) Select the **Coupon-driven** checkbox to manually [create a single code](/docs/commerce-manager/promotions-builder/creating-promotion-codes#creating-a-single-code). If not selected, a promotion code is automatically generated for you.
Expand All @@ -28,26 +28,26 @@ In the **Create your rules** section, do the following:
1. Select a currency for the promotion in the **Currency** field.
1. Choose eligible catalogs for the promotion in the **Catalog** field.
1. Under **Conditions**, select **all** to apply all conditions.
- **Cart**: Configure the promotion by setting either a minimum cart subtotal or quantity of cart items. You can also add conditions to exclude certain items from the cart eligibility. See [Creating a Cart Condition](#creating-a-cart-condition).
- **Cart Items**: Specify the desired product quantity or value. You can also add exclusions that will not contribute to the cart eligibility. See [Creating a Cart Items Condition](#creating-a-cart-items-condition).
- **Custom Attributes**: Define conditions based on custom attributes. See [Adding Cart Custom Attributes](#adding-cart-custom-attributes).
- **Cart**: Configure the promotion by setting either a minimum cart subtotal or quantity of cart items. You can also add conditions to exclude certain items from the cart eligibility. See [Creating a Cart Condition](#creating-a-cart-condition).
- **Cart Items**: Specify the desired product quantity or value. You can also add exclusions that will not contribute to the cart eligibility. See [Creating a Cart Items Condition](#creating-a-cart-items-condition).
- **Custom Attributes**: Define conditions based on custom attributes. See [Adding Cart Custom Attributes](#adding-cart-custom-attributes).

### Creating a Cart Condition

1. Select **Cart** in the **Conditions** section.
1. Set the basic conditions:
1. Choose either **Subtotal** or **Items quantity** to specify a condition for the cart.
1. Select an operator from the following options:
- **is equal to**
- **is greater than**
- **is equal or greater than**
- **is less than**
- **is equal or less than**

1. If you selected **Subtotal**, enter the desired amount. This value is used to determine the subtotal of the cart, based on the operator selected in the previous step. For example, if you selected the **is greater than** operator, the **Subtotal** must exceed the specified amount.
1. If you selected **Items quantity**, enter the required quantity.

You can add multiple conditions according to your business requirements.
1. Choose either **Subtotal** or **Items quantity** to specify a condition for the cart.
1. Select an operator from the following options:
- **is equal to**
- **is greater than**
- **is equal or greater than**
- **is less than**
- **is equal or less than**

1. If you selected **Subtotal**, enter the desired amount. This value is used to determine the subtotal of the cart, based on the operator selected in the previous step. For example, if you selected the **is greater than** operator, the **Subtotal** must exceed the specified amount.
1. If you selected **Items quantity**, enter the required quantity.

You can add multiple conditions according to your business requirements.
1. Define exclusions. To exclude items from the promotion, either select **copy exclusions from actions**, or select **Add an exclusion** and then make changes as needed. See [Adding Exclusions](#adding-exclusions).
1. Click **Done** to apply the conditions.

Expand All @@ -56,9 +56,9 @@ In the **Create your rules** section, do the following:
1. Select **Cart Items** in the **Conditions** section.
1. Choose **is** to include cart items in the promotion.
1. Specify the type of cart items:
- **product**: Select the **+** icon. Then, in the **Select Product** window either select a product from the list or include a custom SKU in the **Add Custom SKU** field. For instructions on searching for products in the **Select Product** window, see [Searching for Products](#searching-for-products).
- **node/hierarchy (category)**: Select the **+** icon and select the hierarchy checkbox. Then, click the hierarchy if you want to add nodes to your promotion conditions.
- **attribute**: Select the template from the list, select the attribute, and then set the value for the selected attribute.
- **product**: Select the **+** icon. Then, in the **Select Product** window either select a product from the list or include a custom SKU in the **Add Custom SKU** field. For instructions on searching for products in the **Select Product** window, see [Searching for Products](#searching-for-products).
- **node/hierarchy (category)**: Select the **+** icon and select the hierarchy checkbox. Then, click the hierarchy if you want to add nodes to your promotion conditions.
- **attribute**: Select the template from the list, select the attribute, and then set the value for the selected attribute.
1. Define exclusions. To exclude items from the promotion, either select **copy exclusions from actions**, or select **Add an exclusion** and then make changes as needed. See [Adding Exclusions](#adding-exclusions)..

1. Click **Done** to apply the conditions.
Expand All @@ -76,10 +76,10 @@ For example, you may want to add a custom attribute for a customer’s membershi
1. Select **Custom Attributes** in the **conditions** section.
1. Enter the name of your attribute key. For example, you can enter *membership level*.
1. Choose one of the following types depending on your attribute key.
- **String**
- **Float**
- **Integer**
- **Boolean**
- **String**
- **Float**
- **Integer**
- **Boolean**
1. Enter the specific value depending on your attribute. For example, *gold* or *silver*.
1. Click **Done** to apply the changes.

Expand Down Expand Up @@ -133,12 +133,12 @@ To create a BXGY promotion, do the following:
1. If you selected **amount**, specify the amount for the promotion.
1. Select **all**, **cheapest**, or **most expensive** items in the cart to qualify for the promotion.
1. Specify the type of items to include in the promotion from the following options:
- **product**: Select the **+** icon. Then, in the **Select Product** window either select a product from the list or include a custom SKU in the **Add Custom SKU** field. For instructions on searching for products in the **Select Product** window, see [Searching for Products](#searching-for-products).
- **node/hierarchy (category)**: Select the **+** icon and select the hierarchy checkbox. Then, click the hierarchy if you want to add nodes to your promotion.
- **Attribute**: To add the attribute, do the following:
1. Select the template from the list.
1. Select the attribute from the list.
1. Select the value from the list corresponding to the chosen attributes.
- **product**: Select the **+** icon. Then, in the **Select Product** window either select a product from the list or include a custom SKU in the **Add Custom SKU** field. For instructions on searching for products in the **Select Product** window, see [Searching for Products](#searching-for-products).
- **node/hierarchy (category)**: Select the **+** icon and select the hierarchy checkbox. Then, click the hierarchy if you want to add nodes to your promotion.
- **Attribute**: To add the attribute, do the following:
1. Select the template from the list.
1. Select the attribute from the list.
1. Select the value from the list corresponding to the chosen attributes.
1. Define exclusions. To exclude items from the promotion, either select **copy exclusions from conditions**, or select **Add an exclusion** and then make changes as needed. See [Adding Exclusions](#adding-exclusions).
1. Click **+ more options**.
1. Enter the value to assign a maximum allowed discount for the promotion. This field is shown only if you choose **percentage** as your discount type.
Expand All @@ -158,7 +158,7 @@ To create a shipping discount promotion, do the following:
1. (Optional) If there is targeted shipping type for discount, then select **+ more options**.
1. Check the checkbox **Apply discount to**.
1. Enter the shipping type value that matches targeted cart shipping group `shipping_type` value and hit Enter. For example, "fedex", "UPS".
- You can add more than one.
- You can add more than one.
1. Click **Done** to apply the changes.

## Adding Exclusions
Expand All @@ -167,27 +167,27 @@ Exclusions allow you to exclude specific items from the promotion, ensuring they

1. Select **Add an exclusion**.
1. Choose one of the following exclusion types:
- **product**: Enter the values directly or select **view list**. In the **Select Product** window, either choose a product from the list or enter a custom SKU. in the **Add Custom SKU** field. For instructions on searching for products in the **Select Product** window, see [Searching for Products](#searching-for-products).
- **node/hierarchy (category)**: Either enter the unique identifiers directly or select **view list**, then select the checkboxes for the desired nodes/hierarchies(categories).
- **attribute**: Select the template from the list, choose the attribute, and then set the value for the selected attribute.
- **product**: Enter the values directly or select **view list**. In the **Select Product** window, either choose a product from the list or enter a custom SKU. in the **Add Custom SKU** field. For instructions on searching for products in the **Select Product** window, see [Searching for Products](#searching-for-products).
- **node/hierarchy (category)**: Either enter the unique identifiers directly or select **view list**, then select the checkboxes for the desired nodes/hierarchies(categories).
- **attribute**: Select the template from the list, choose the attribute, and then set the value for the selected attribute.
1. Click **Done** apply the exclusions.

## Searching for Products

To find specific products to include in your promotion, follow these steps in the **Search Product** Window:

1. In the first column, select the drop-down arrow and choose any one of the following options to search for the product based on:
- **SKU**
- **Name**
- **Slug**
- **UPC/EAN**
- **MPN**
- **Description**
- **SKU**
- **Name**
- **Slug**
- **UPC/EAN**
- **MPN**
- **Description**
1. In the next column, select the drop-down arrow and choose any one of the following options:
- **is**
- **is like**
- **ends with**
- **starts with**
- **is**
- **is like**
- **ends with**
- **starts with**

1. In the **Find product** field, enter the desired value based on your selection in the previous steps.
1. Select **Search**.
Expand All @@ -198,11 +198,21 @@ You can duplicate an existing promotion and reuse its details as required in a n

1. Go to **STORE > Promotions Builder**.
1. To duplicate a promotion, follow one of these steps on the **All Promotions** page:
- In the **Actions** column, click the ellipsis next to the promotion's name, then select **Duplicate**.
- Open the promotion you want to duplicate, and click **Duplicate** at the bottom of the page.
- In the **Actions** column, click the ellipsis next to the promotion's name, then select **Duplicate**.
- Open the promotion you want to duplicate, and click **Duplicate** at the bottom of the page.

The duplicated promotion opens. Make the necessary updates, then click **Create Promotion** to save the new promotion.

## Editing Custom Fields in a Promotion
In order to use custom fields in Promotions Builder, you need to create flows in the store. See [Creating FLows](/docs/commerce-manager/flows) for how to create flows. The **slug** value for promotions builder is **rule-promotions**.
Once you have created the flows and field, then you can edit the custom fields in promotions builder.

1. In the promotions builder editing page, locate the **Custom Fields** at the bottom of page.
1. Expand the section.
1. Edit the fields.
1. Click **Save** to save the changes.

The duplicated promotion opens. Make the necessary updates, then click **Create Promotion** to save the new promotion.

## Related Resources

- [Rule Promotions API](/docs/rule-promotions/overview)
- [Rule Promotions API](/docs/promotions-builder/promotions-builder-api/promotions-builder-api-overview)
1 change: 0 additions & 1 deletion docusaurus.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -642,7 +642,6 @@ const config = {
{
redirects: [
// /docs/oldDoc -> /docs/newDoc
{ to: '/docs/api/commerce-extensions', from: '/docs/api/commerce-extensions/commerce-extensions-introduction'},
{ to: '/docs/studio/developers/custom-themes/css-variables', from: '/docs/cx-studio/developers/custom-themes/css-variables'},
{ to: '/docs/studio/Insights/Setting-up-an-AB-Test', from: '/docs/cx-studio/Insights/Setting-up-an-AB-Test'},
{ to: '/changelog/Studio-Release-Notes/2022/Release-145-July-17-2022', from: '/docs/cx-studio/Release-Notes/2022/Release-145-July-17-2022'},
Expand Down
4 changes: 4 additions & 0 deletions guides/How-To/promotions-builder/_category_.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"position": 85,
"label": "Promotions Builder"
}
14 changes: 14 additions & 0 deletions guides/How-To/promotions-builder/buy-x-get-y-promotion.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
title: Creating a Buy X Get Y (BXGY) Promotion
nav_label: Buy X, Get Y Promotion
sidebar_position: 20
---

Let's consider a scenario where you want to offer a discount on silver jewelery for shoppers who buy gift cards for the holidays.

To set this up in the Promotions Builder:

1. Configure a [Cart Items condition](/docs/commerce-manager/promotions-builder/creating-a-promotion-in-promotions-builder#creating-a-cart-items-condition), and select **Product** option and add the eligible gift card items.
2. Create a [BXGY](/docs/commerce-manager/promotions-builder/creating-a-promotion-in-promotions-builder#creating-a-bxgy-promotion) promotion in the **Actions** section. Configure an item discount for 70% off on all products with the *jewellery-metal-type* template, which contains *metal-type* with values as *silver*.

![Creating a Buy X Get Y (BXGY) Promotion](/assets/promotion-example-scenario-2.png)
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
---
title: Creating a Promotion to Exclude Products from Both Eligibility and Discount
nav_label: Excluding Items from Promotion Eligibility
sidebar_position: 80
---

Let's say you want to create a promotion where specific products are excluded from both making the cart eligible for a discount
and from receiving the discount themselves.

In this scenario, if shoppers buy any product from the *Fashion Rings* category, they can receive a 20% discount on other
products from the *Fashion Rings Jewellery* category. However, products with the attribute *Platinum Metal Type* are excluded.
This means these products will not make the cart eligible for the discount, nor will they receive the discount if they are included in the cart.

To set this up in the Promotions Builder:

1. **Add a condition and exclusions**: Select the eligible category for the promotion condition, such as the *Fashion Rings* category, to define which products can qualify for the discount, and specify any products or attributes to be excluded from the promotion. For example, exclude products with the *Platinum Metal Type* attribute to ensure they do not make the cart eligible for a discount.
1. **Configure the action and exclusions**: Configure a BXGY promotion in the **Actions** section to offer 20% off products in the *Fashion Rings Jewellery* category. After configuring the action, add exclusions to ensure that products with the *Platinum Metal Type* attribute are also excluded from receiving the discount. See [Creating a BXGY Promotion](/docs/commerce-manager/promotions-builder/creating-a-promotion-in-promotions-builder#creating-a-bxgy-promotion).

![Creating a Promotion to Exclude Products from Both Eligibility and Discount](/assets/promotion-example-scenario-7-2.png)
Loading