Packing Slips: group/sort by Product Type?

Packing Slips: group/sort by Product Type?

160 2 146

I'd like my packing slip items to be grouped by Product Type. 


I have tried this code with no luck:


In the Packing Slip template, replaced:


{% for line_item in line_items_in_shipment %}



{% assign lineitems = line_items_in_shipment | sort: "line_item.product.type" %}
{% for line_item in lineitems %} 

I pulled the basic code from this post, where some people had luck sorting alphabetically. 


I pulled the sort criteria from this post. Not sure it's even the correct sorting criteria. 

Monster, creature & cryptozoology patches, buttons & stickers.
Replies 0 (0)