Merging line item quantities with the same SKU on packing slips
In Simple Bundles 1.0, the same SKU can show up on several lines of a packing slip when it's in more than one bundle. To merge line items with the same SKU into one line with the total quantity, replace the line item code in your Shopify packing slip template with the Liquid snippet below.
Using Simple Bundles 2.0? See Show itemized bundles items on Simple Bundles 2.0 using Shopify packing slips.
Note: All products in orders (both bundle and non-bundle items) must have a SKU for this packing slip template edit to work.
How do I merge same-SKU line items on Shopify packing slips?
-
In Shopify, go to Settings and click Shipping and delivery.

-
Scroll down to the Documents section and click Packing slip template.

-
Find the line of code shown below and replace it with the code from the GitHub Gist.

You can find the code snippet here: Github Gist

In the line item list for loop, replace all instances of:
- line_item.shipping_quantity with total_shipping_quantity
-
line_item.quantity with total_quantity
Before:

After:

Once you've added all the edits to the template, line items with the same SKU are merged.
What does the packing slip look like after the edit?
Packing slip before edits

Packing slip after edits

Can I use this snippet in other packing slip apps?
Yes. You can also use this snippet in Shopify Order Printer or Order Printer Pro, as long as line_items_in_shipment has been modified based on the templates being used.
Related articles
Hiding bundles from Shopify packing slips
Hiding bundle items from Order Printer Pro receipts and packing slips
Show itemized bundles items on Simple Bundles 2.0 using Shopify packing slips





