MDVA-42584: Stock status of configurable product not updated automatically
The MDVA-42584 patch solves the issue where the stock status of the configurable product is not updated automatically when its simple product is updated. This patch is available when the Quality Patches Tool (QPT) 1.1.10 is installed. The patch ID is MDVA-42584. Please note that the issue is scheduled to be fixed in Adobe Commerce 2.4.5.
Affected products and versions
The patch is created for Adobe Commerce version:
- Adobe Commerce (all deployment methods) 2.4.2-p2
Compatible with Adobe Commerce versions:
- Adobe Commerce (all deployment methods) 2.4.2 - 2.4.2-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
Stock status of the configurable product in the backend is not updated automatically when its simple product is set to In Stock through API or import.
Prerequisites:
MSI installed.
Steps to reproduce:
-
Create a configurable product, InvCheck001, with two options: InvCheck001-M and InvCheck001-L.
-
Both the simple products should have Quantity and they should be In Stock so that the configurable product is also In Stock in the backend.
-
Now, update both simple products and set Quantity to 0 and Stock Status to Out of Stock.
-
Refresh the configurable product and verify the stock status is updated to Out of Stock.
-
Use the following API endpoint and set the simple product InvCheck001-M to In Stock with Quantity > 0.
code language-json /rest/V1/inventory/source-items { "sourceItems": [ { "sku": "InvCheck001-M", "source_code": "default", "quantity": 10, "status": 1 } ] }
-
Go to the backend and verify the quantity and stock status of the simple product InvCheck001-M. It is updated to In stock.
-
Refresh the configurable product and check the stock status.
Expected results:
The stock status of the configurable product InvCheck001 in the backend is updated automatically to In Stock.
Actual results:
The stock status of the configurable product is still Out of Stock.
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.