My products say "THIS PRODUCT IS OUT OF STOCK"

Solved
Highlighted
Tourist
4 1 0

Newbie here... Below all of my items, it says "THIS PRODUCT IS OUT OF STOCK" below the description. There is plenty of inventory and customers are able to add to their carts. How do I remove that "THIS PRODUCT IS OUT OF STOCK" message?

 

Thank you

PPEPro.care

0 Likes
Highlighted
Shopify Staff
Shopify Staff
375 29 51

Hi, @dglenn

 

Ash here from the Shopify team. Welcome to the Shopify Community! 

 

This definitely sounds like an odd issue, and I'm happy to help get to the bottom of this. I have a few troubleshooting questions that will help determine what's causing this. Could you please reply back and let me know the following:

 

  • If you check an affected product in the admin, is the text in question in the product description? 
  • Have you made any code changes in your theme recently? 
  • Have you installed any new applications recently? 
  • What theme are you using? 
  • Could you please send me a screenshot of the text, or a link to an affected product page? 

I look forward to hearing back and working towards getting this resolved. 

Ash | Social Care @ Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit the Shopify Help Center or the Shopify Blog

0 Likes
Highlighted
Tourist
4 1 0

Ash,

 

Thank you for your reply.

If you check an affected product in the admin, is the text in question in
the product description? No, the text isn't there.

Have you made any code changes in your theme recently? Yes, added the
following to line 111 in product-template.liquid. We were wanting to show
inventory quantities.

 

 {% comment %} Inventory tracking on product page {% endcomment %}
<div id="variant-inventory" class="{% unless current_variant.available %} hide {% endunless %}">
{% if current_variant.inventory_management == "shopify" and current_variant.inventory_policy != "continue" %}
{{ current_variant.inventory_quantity }} remaining in stock.
{% else %}
This product is available.
{% endif %}
</div>

Have you installed any new applications recently? No

What theme are you using? Simple

Could you please send me a screenshot of the text, or a link to an affected
product page? All of the products

https://ppepro.care/products/hanes-cotton-mask
https://ppepro.care/products/disposable-mask-500
https://ppepro.care/products/isolation-gown
https://ppepro.care/products/kn95-respirator
https://ppepro.care/products/disposable-mask-2-500

Thank you for your assistance.


David

0 Likes
Highlighted
Shopify Staff
Shopify Staff
375 29 51

Hi, @dglenn!

 

Thank you for getting back to me with this additional information!

 

While I'm not a code expert, my suspicion is that the code customization made to the product-template.liquid is likely causing this issue. To confirm this, could I get you to reverse the code customization, and preview your product pages to see if the issue persists? We have some great information here on how to roll back sections of your theme code to previous versions. 

 

If that resolves the issue, then that confirms the custom coding is what's causing the "THIS PRODUCT IS OUT OF STOCK" text. If that is the case, may I please also know where you acquired this custom coding? Was this done by a hired developer, or did you follow a tutorial, or was it acquired by some other method? 

 

Looking forward to hearing back and continuing to work on this with you. 

Ash | Social Care @ Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit the Shopify Help Center or the Shopify Blog

0 Likes
Highlighted
Tourist
4 1 0

I will roll back.

 

Do you have another option to show inventory? I found this code in the community here.

0 Likes
Highlighted
Tourist
4 1 0

This is an accepted solution.

Found the rouge code.

0 Likes
Highlighted
Shopify Staff
Shopify Staff
375 29 51

Hi, @dglenn!

 

I'm glad to hear you were able to track down the rouge code. I'm also happy to help look for an alternate solution that hopefully won't cause any issues like this. Just to confirm your goal, did you want your customers to be able to see how much inventory of each product is available when looking at a product on your store? Also, could you please send me a link to the tutorial that you originally followed? 

 

Looking forward to hearing back! 

Ash | Social Care @ Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit the Shopify Help Center or the Shopify Blog

0 Likes