New Shopify Certification now available: Liquid Storefronts for Theme Developers

How to add a custom .product metafield to packing slip template

Amir212
New Member
4 0 0

Hi,

I'm trying to add

product.metafields.custom.weight

to my line item description section in packing template manually.

 

The goal is to display the weight of a sold item under its name and picture on the slip.

 

I understand metafields need a loop to be added, tried some of the suggested loops in the forum and it didn't work.

 

Any suggestions please?

Replies 3 (3)
ZenoPageBuilder
Shopify Partner
841 150 168

You can show the metafield with this code

{{ product.metafields.custom.weight | metafield_tag }}
Zeno Page Builder - Build responsive & SEO-optimized Landing pages, Blog posts, Product pages and more...
Learn more at zenobuilder.com
Amir212
New Member
4 0 0

Thank you for your reply, but it didn't work.

 

From what I read it has to be a loop, but can't get the right loop for this one.

Liam
Shopify Staff
Shopify Staff
1897 202 577

Hi Amir212,

 

It doesn't look like product metafields are supported on packing slips yet, but I've passed on this request to our internal dev team.

 

Thanks for your feedback!

Liam | Developer Advocate @ 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 Shopify.dev or the Shopify Web Design and Development Blog