If items are no longer in stock, display a different text?

MarcoAP
Tourist
16 0 2

Hello,
I would like to resell a product even if we no longer have it in stock. Then we give a delivery time.

If the option "Continue selling when out of stock" is activated, the item is displayed, even if the quantity
is 0. Can I bypass this and display a different text if the quantity is 0 ... like "Not in stock, but will be
ordered for you"? Is it possible to query the status of "Continue selling when out of stock"
via Liquid and then to compare the quantity and status?

Thanks
Marco

 

These settings indicate that the item is in stock ... I want to change that.

Bildschirmfoto 2021-07-31 um 10.42.35.png

0 Likes
drakedev
Shopify Partner
592 127 158

Hi,

you could use variant.inventory_policy in combination with variant.inventory_quantity

variant.inventory_policy
Returns the string continue if the "Allow users to purchase this item, even if it is no longer in stock." checkbox is checked in the variant options in the Admin. Returns deny if it is unchecked.

• If my answer helped click Like to say thanks
• If the problem is solved remember to click ✅ Accept Solution
• Shopify/Shopify Plus custom development, optimization and consulting. You can hire me here.
0 Likes