Adding specifc product tag to cart line items

Hello All!

We have a lead time message based on specific tags that displays for certain products on the product page. For example, someone clicks on bowl in on a collection page and that bowl has a lead time of 1-2 weeks from purchase date, a message will appear above the Add to Cart button that reads, “lead time is approximately 1-2 weeks”. That is generated with if statements in the product template stating that if a product has the tag “LT12” display that message. We have several others based on the lead time (4-6 weeks, 8-10 weeks, etc), all done by tags. We would love to add that to the line items on the cart page too so it displays just below the item name.

*** Figured it out. I had something above the code written incorrectly. Oopsie! :slightly_smiling_face: Tried to delete post but couldn’t.

Hi @jdashley

I understand your requirement I think you want delivery time on the basis of tag. Use this code on product-template.liquid fille within the form tag. It may be helpful for you

{% if product.tags contains ‘LT12’ %}

1-2 weeks

{% elsif product.tags contains ‘LT46’ %}

4 - 6 weeks

{% elsif product.tags contains ‘LT810’ %}

8 - 10 weeks

{% else %}

{% endif %}

Thanks