I am working on a store with thousands of products. I have noticed that when product Quantity is zero (or manually turned to Zero) the Stock Availability goes 'Out of Stock' however when we update the product Quantity to number greater then zero like 10,15 or 200 the 'Stock Availability' stays 'Out of Stock' unless and until manually changed to 'In Stock' so that the product appears on frontend.
I want the 'Stock Availability' to Auto turned to 'In Stock' as we update the Quantity to number greater then Zero. The Quantity in my case gets its values from the store inventory software we don't change it manually.
Magento – How to auto turn on ‘Stock Availability’ to ‘In Stock’ after Quantity is updated from 0 to any number greater
productquantity
Related Topic
- Magento – Products are not showing on category and search result
- Magento – Auto Save In Stock if Quantity Greater Than 0
- Magento – Products still showing out of stock
- Magento – Magento 2 How to decrease product qty from source same as “Product Salable qty” after orderd placed to make product out of stock
Best Answer
you can use Magento event
catalog_product_save_after
.write this in your
config.xml
fileCreate an observer method
changeStockStatus()
at below locationyour_module/Model/Observer.php
that does the following on eventcatalog_product_save_after
.