MDVA-30837: minimum order amount for free shipping
The MDVA-30837 patch adds configuration options for the free shipping calculation so the user can configure the Minimum Order Amount to get Free Shipping based on the Subtotal (or Grand Total). This allows local customizations for tax and shipping methods. This patch is available when the Quality Patches Tool (QPT) 1.0.7 is installed. Please note that the issue was fixed in Adobe Commerce 2.4.2.
Affected products and versions
The patch is created for Adobe Commerce version:
- Adobe Commerce on cloud infrastructure 2.3.4-p2
Compatible with Adobe Commerce versions:
- Adobe Commerce on cloud infrastructure 2.3.1 - 2.3.4-p2
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 patch MDVA-30837 adds the configuration setting to configure the Minimum Order Amount setting to get free shipping based on the Subtotal (or Grand Total):
-
Include Tax to Amount: Yes/No in the Free Shipping method configuration.
- When Include Tax to Amount is set to Yes, the minimum order amount is calculated as Subtotal + Tax - Discount.
- When Include Tax to Amount is set to No, the minimum order amount is calculated as Subtotal - Discount.
Steps to reproduce:
-
Go to Stores > Settings > Configuration > Sales > Tax and set the following:
- Tax Calculation Based on Shipping Address
- Enable Cross Border Trade: No
- Display Produce Prices in Catalog: Excluding Tax
- Display Shipping Prices: Excluding Tax
- Display Prices: Excluding Tax
- Display Subtotal: Excluding Tax
- Display Shipping Amount: Excluding Tax
- Display Gift Wrapping Prices: Excluding Tax
- Display Printed Card Prices: Excluding Tax
- Include Tax in Order Total: Yes
- Display Full Tax Summary: Yes
-
Go to Sales > Shipping Settings > Free Shipping and set Minimum Order Amount = 30.
-
Go to Marketing > Promotions > Cart Price Rules and create a new price rule (for detailed steps, refer to Create a Cart Price Rule in our user guide).
- Coupon Code = Specific Coupon.
- Conditions: Subtotal equals or greater than $25.
- Actions: Free Shipping = For shipments with matching items.
-
Create a product with a price of $23.10.
-
Add the CA tax to the default tax rule.
-
Add this product to the cart.
-
Get a shipping quote - after taxes, the Grand Total = $25.01 and free shipping is applied.
-
Apply the coupon code - it will not be valid because the Subtotal (Excluding Tax) is $23.10.
Expected results:
There is an additional configuration setting - Include Tax to Amount: Yes/No in Free Shipping method configuration:
- When Include Tax to Amount is set to Yes, the Minimum Order Amount is calculated as Subtotal + Tax - Discount.
- When Include Tax to Amount is set to No, the Minimum Order Amount is calculated as Subtotal - Discount.
Actual results:
The Free Shipping price rule condition can only be based on the Subtotal, while the Free Shipping method can only be based on the Grand Total.
Apply the patch
To apply individual patches, use the following links depending on your deployment method:
- Adobe Commerce or Magento Open Source on-premises: Software Update Guide > Apply Patches in our developer documentation.
- Adobe Commerce on cloud infrastructure: Upgrades and Patches > Apply Patches in our developer documentation.
Related reading
To learn more about Quality Patches Tool, refer to:
- Quality Patches Tool released: a new tool to self-serve quality patches in our support knowledge base.
- Check if patch is available for your Adobe Commerce issue using Quality Patches Tool in our support knowledge base.
For info about other patches available in QPT, refer to Patches available in QPT in our developer documentation.