[HACK] Listing products on invoices by SKU

For Articles relating to more than one ISC version
Post Reply
Brandeline
Posts: 76
Joined: Thu Sep 16, 2010 4:12 am

[HACK] Listing products on invoices by SKU

Post by Brandeline »

If you are like me and have more than 1300 different SKU's for a warehouse to manage the picking and packing of, you might have noticed that sometimes, products do not appear sensibly in SKU order on the invoices. This makes it fairly hard for warehouse staff to get everything they need for a large order in one trip to an area and wastes steps. This tiny hack is for 6.1.1, to print invoices with products in sku order per shipment address.

Open lib/order.printing.php
1. Around line 272 inside the function generatePrintableInvoice find this line of code

Code: Select all

ORDER BY op.order_address_id
and change it to the following:

Code: Select all

ORDER BY op.order_address_id, p.prodcode ASC
To make the same change for packing slips:

Around line 763 inside the function generateOrderPackingSlip find the following:

Code: Select all

WHERE orderorderid='".(int)$orderId."'
and add this line below it

Code: Select all

ORDER BY ordprodsku ASC
meules
Confirmed
Confirmed
Posts: 95
Joined: Wed Jun 17, 2009 8:56 pm
Location: NL

Re: [HACK] Listing products on invoices by SKU

Post by meules »

Great, it was exactly one minute ago that I was frustrated while picking an order that products were not ordered on name. Had to go back to the same rack four times :evil: I assume that the same order can be done on name?

Anyway thx
ISC v6
Martin
Site Admin
Site Admin
Posts: 1854
Joined: Wed Jun 17, 2009 6:30 pm
Location: South Yorkshire UK
Contact:

Re: [HACK] Listing products on invoices by SKU

Post by Martin »

meules wrote:Great, it was exactly one minute ago that I was frustrated while picking an order that products were not ordered on name. Had to go back to the same rack four times :evil: I assume that the same order can be done on name?
Yup..

Just go with:

Code: Select all

ORDER BY ordprodname ASC 
instead of:

Code: Select all

ORDER BY ordprodsku ASC 

Thanks to Brandeline for that simple but effective little hack.. :ugeek:
noticz
Posts: 19
Joined: Wed Aug 10, 2011 3:40 am
Location: SLC, Utah

Re: [HACK] Listing products on invoices by SKU

Post by noticz »

OK I got one for you, how about printing multiple invoices IN ORDER by product name or sku?

Hell if you are going to do the individual invoice items by SKU might as well do all them and have them ordered in a row so your guys and pull them and save more time there.
noticz
Posts: 19
Joined: Wed Aug 10, 2011 3:40 am
Location: SLC, Utah

Re: [HACK] Listing products on invoices by SKU

Post by noticz »

Actually what I mentioned above was pretty simple to figure out. Instead of having the invoices sorted I just created another db query then changed up the order before it displays the invoice template for each. If anyone is interested I can post it however I am on 5.0.2
Post Reply