All things Shopify and commerce
We're moving the community! Starting July 7, the current community will be read-only for approx. 2 weeks. You can browse content, but posting will be temporarily unavailable. Learn more
Hello Team!
I am looking for to add country_of_origin of the Product on email notifications.
For Ex: Order invoice Notification.
The value is already added on the Product at admin side.
I have try many solution but not succeed.
Try with below code:
{{ line.variant.metafields.custom.country_of_origin }}
{{ line_item.product.metafields.custom.country_of_origin }}
Thanks in advanced!
Mohit P.
Hi @mohitp
You can consider trying the below code to see if it works:
{% for line in order.line_items %}
<tr>
<td>{{ line.product.title }}</td>
<td>{{ line.quantity }}</td>
<td>{{ line.price }}</td>
<td>{{ line.variant.metafields.custom.country_of_origin }}</td>
</tr>
{% endfor %}
I hope this can help.