do you know how to show the product "variants" (sorry if this terminology is incorrect) even if it is out of stock and possibly show "Out of stock" instead of the price?
So for example I have a T-shirt configurable product, so I have added a green single product and an orange single product as Associated products. The orange product is out of stock, I still want it to be displayed in the dropdown menu so customers know that there's an orange option but it should be out of stock so the customer can't order.
Does anybody know?
Best Answer
You can view out of stock variable in product by remove this code
if ($product->isSaleable() || $skipSaleableCheck) {
from functiongetAllowProducts()
at classMage_Catalog_Block_Product_View_Type_Configurable
.So you need to
rewrite
classMage_Catalog_Block_Product_View_Type_Configurable
Step1: You will need to create
/app/code/local/Amit/MyProduct/Block/Catalog/Product/View/Type/
and fileConfigurable.php
and code:
Step2: create config.xml
/app/code/local/Amit/MyProduct/etc/
and code isStep3: Create
Amit_MyProduct.xml
at app/etc/modules