Show inventory quantities on product pages for different variants

Highlighted
Tourist
7 0 1

Hi,

 

I have some trouble with showing inventory on the productpage for different sizes.

I tried it using this link: https://community.shopify.com/c/Shopify-Design/How-do-I-Show-inventory-quantities-on-product-pages-u..., but it does not work for different sizes.

 

This is the code I used:

<div id="variant-inventory">
{% if product.variants.first.inventory_management == "shopify" %}
{% if product.variants.first.inventory_quantity > 0 %}
We currently have {{ product.variants.first.inventory_quantity }} in stock.
{% else %}
The product is out of stock
{% endif %}
{% else %}
This product is available
{% endif %}
</div>

 

Website URL: sxcript.com

Password: Coming-soon!

 

The theme I am using is Debut. I would really appreciate it if someone could help me with this or point me in the right direction 😊

 

 

0 Likes
Highlighted
Shopify Partner
149 6 15

Hello User6,

We have the perfect solution for inventory status on the item page (instock/out of stock/pre-order,  for different variants/options -  https://www.centrifugeconnect.com/ 

 

Take a look at a Shopify store example and let me know what you think -  https://outdoorlegacygear.com/

 

1 Like
Highlighted
Tourist
7 0 1

Hi Shipguru,

 

Looks nice!

But I would like to solve this without spending money.

Thanks for the tip. 

 

0 Likes
Highlighted
Shopify Partner
149 6 15

No problem - we are reviewing the code for possible solution.  Your patience is much appreciated.

0 Likes