ACSD-59865: Cart Price Rule fails to cancel previous rules due to insufficient product quantity
The ACSD-59865 patch fixes the issue where the Discount quantity step value in Fixed amount discount, Percent of product price discount, and Buy X get Y Cart Price Rules no longer cancels the action of previous rules. This patch is available when the Quality Patches Tool (QPT) 1.1.52 is installed. The patch ID is ACSD-59865. Please note that the issue is scheduled to be fixed in Adobe Commerce 2.4.8.
Affected products and versions
The patch is created for Adobe Commerce version:
- Adobe Commerce (all deployment methods) 2.4.6-p1
Compatible with Adobe Commerce versions:
- Adobe Commerce (all deployment methods) 2.4.4 - 2.4.6-p7
magento/quality-patches
package to the latest version and check the compatibility on the Quality Patches Tool: Search for patches page. Use the patch ID as a search keyword to locate the patch.Issue
The Cart Price Rule fails to cancel previously applied rules due to an insufficient product quantity in the cart.
Steps to reproduce:
-
Log in as an admin.
-
Go to Marketing > Cart Price Rules and click on Add New rule.
-
Set Rule Name = Test - 1
-
Select all Websites and Customer groups
-
Set Priority = 0
-
Go to the Actions section:
- Set Apply = Percent of product price discount
- Set Discount amount = 10
- Set Maximum Qty Discount is Applied To = 100
- Set Discount Qty Step (Buy X) = 0
- Set Discard subsequent rules to No
-
-
Clear the cache.
-
Go to the Storefront, add one item to the cart, and proceed to checkout/cart.
-
Verify that the 10% discount is applied to your cart.
-
Return to the Cart Price Rules and create a new rule.
-
Set Rule Name = Test - 2
-
Select all Websites and Customer Groups
-
Set Priority = 2
-
Navigate to the Actions section:
- Set Apply = Percent of product price discount
- Set Discount amount = 20
- Set Maximum Qty Discount is Applied To = 100
- Set Discount Qty Step (Buy X) = 3
-
-
Clear the cache.
-
Go back to the Storefront again.
-
Update the cart to refresh the rules. Verify that the 10% discount is no longer applied.
-
Add items to your cart until the quantity meets the Step value required for the second rule.
Expected results:
The first Cart Price Rule is applied when the conditions of second rule are met.
Actual results:
Price rules are applied as configured in the admin dashboard.
Apply the patch
To apply individual patches, use the following links depending on your deployment method:
- Adobe Commerce or Magento Open Source on-premises: Quality Patches Tool > Usage in the Quality Patches Tool guide.
- Adobe Commerce on cloud infrastructure: Upgrades and Patches > Apply Patches in the Commerce on Cloud Infrastructure guide.
Related reading
To learn more about Quality Patches Tool, refer to:
- Quality Patches Tool released: a new tool to self-serve quality patches in the support knowledge base.
- Check if patch is available for your Adobe Commerce issue using Quality Patches Tool in the Quality Patches Tool guide.
For info about other patches available in QPT, refer to Quality Patches Tool: Search for patches in the Quality Patches Tool guide.