cancel
Showing results for 
Search instead for 
Did you mean: 

Magento 2.3.5-p1 out of stock attribute/swatch is not crossed

Highlighted

Magento 2.3.5-p1 out of stock attribute/swatch is not crossed

Hey,

I created a test configurable product and then placed maximum order on small size, so now product with size “S” is out of stock, but on front-end it does not show as crossed out. When I click it and place order then only it prompts that this item is out of stock.

I found that it was bug in 2.2.2, but I am using Magento 2.3.5-p1, so any solution for this?

 

Screen Shot 2020-07-27 at 11.35.48 AM.png

 

Although, other sizes “M”,“L”, are in stock and i can order, but I suppose, “S” should be crossed out. Is there any specific settings for this?

8 REPLIES 8
Highlighted

Re: Magento 2.3.5-p1 out of stock attribute/swatch is not crossed

Hello @johndoe86cd ,

 

The product is still has add to cart option because it's status is not changed to OUT OF STOCK, check once in admin the status of product.

 

this generally occurs when product has 0 quantity but still it's status is in-stock.

 

Problem Solved ? Click on 'Kudos' & Accept as Solution to encourage to write more answers !
Highlighted

Re: Magento 2.3.5-p1 out of stock attribute/swatch is not crossed

Its a configurable product, and virtual product of size "S" has now quantity "0". 

 

in Catalog > Product, this is enabled, and in configuration its Stock Status is "Out of Stock".

 

Check the image:

 

Screen Shot 2020-07-27 at 12.54.13 PM.png

Highlighted

Re: Magento 2.3.5-p1 out of stock attribute/swatch is not crossed

this could be an indexing issue. Go to System > Index Management and index anew "Stock Status", in this case run below command :

php bin/magento indexer:reindex

If this doesn't help, another possible reason is that your custom settings do not filter products correctly by "Out Of Stock".

To test if this is the case, switch to a default theme and try to reproduce this error.

Problem Solved ? Click on 'Kudos' & Accept as Solution to encourage to write more answers !
Highlighted

Re: Magento 2.3.5-p1 out of stock attribute/swatch is not crossed

Hi @johndoe86cd ,

 

Can you also cross check whether backorders are enabled at your site or not from below link:

https://docs.magento.com/user-guide/catalog/inventory-backorders.html

 

Cross check the settings at product level as well if default configurations are set to NO.

 

Hope this helps you!

Problem Solved! Click Kudos & Accept as Solution!

Highlighted

Re: Magento 2.3.5-p1 out of stock attribute/swatch is not crossed

I have backorders setting to "No Backorders", so i suppose its correct settings.

 

However, I am currently using Claue theme, and noticed that they too have this issue on their demo, perhaps its their functionality, but which I do not want.

 

So, can you please tell or put me in the right direction as how can I alter the code, which files to alter to enable this feature?

Highlighted

Re: Magento 2.3.5-p1 out of stock attribute/swatch is not crossed

Hi @johndoe86cd ,

 

Generally there should be some configurations in theme settings to enable and disable this feature. First check with the theme vendor for the same.

 

If you still didn't get any help from theme vendor

Please check this module available for free.

https://github.com/interjar/configurable-child-visibility

 

Hope this helps you!

Problem Solved! Click Kudos & Accept as Solution!

Highlighted

Re: Magento 2.3.5-p1 out of stock attribute/swatch is not crossed


@Nishu Jindal wrote:

Hi @johndoe86cd ,

 

Generally there should be some configurations in theme settings to enable and disable this feature. First check with the theme vendor for the same.

 

If you still didn't get any help from theme vendor

Please check this module available for free.

https://github.com/interjar/configurable-child-visibility

 

Hope this helps you!

Problem Solved! Click Kudos & Accept as Solution!


will this plugin cross out out of stock products?

Highlighted

Re: Magento 2.3.5-p1 out of stock attribute/swatch is not crossed

Hi @johndoe86cd,

 

You need to cross-check the plugin whether it worked according to your requirements or not.

 

Thanks!