pickPack Advanced Setup - M2
Contents
Aims & Preparation
Most of this is included in the Installation & Pro Setup Service
We're going to dive into some of the more advanced features of pickPack.
Attach pickPack PDFs to Magento 2 Emails
Let's attach pickPack PDFs to emails. They look great, help promote your brand, and provide valuable information.
- Send your customers a nice Invoice in their order email.
- Include a copy of the Packing Sheet in the shipping confirmation email.
- Send your accountant an Invoice as soon as each sale happens.
You need to be on the Startup or Pro Plan to do this
This is pretty easy - we just need to add a short code to your Email Templates, and pickPack will do the rest.
Remember that one of pickPack's great features is being able to generate an Invoice without actually invoicing the order in Magento first. Handy if you're not actually billing customers until you've confirmed the shipment - you can send an order confirmation email.
1. Setup Email Templates
(Also known as Transactional Emails)
First step is to check that you have proper Email Templates setup.
- Edit the MarketingEmail Templates email that you want to attach one of pickPack's PDFs to.
- At the bottom of the content, add the relevant code from here:
- To attach an Invoice:
<pickpack_attachment type="invoice">{{var order.id}}</pickpack_attachment>
- To attach a Packing Sheet:
<pickpack_attachment type="packing_sheet">{{var order.id}}</pickpack_attachment>
- To attach a Credit Memo:
<pickpack_attachment type="credit_memo">{{var order.id}}</pickpack_attachment>
Set 'pickpack_attachment type' according to this list:
- packing_sheet
- invoice
- combined
- separated
- credit_memo
- zebra
The type of PDF available to be attached depends on your pickPack plan
2. Test
Place some sample orders, and check the expected order emails come through. Quite a few Magento extensions rewrite the email code, so you do need to check all is working after install.
- We made this compatible with Mailchimp/Mandrill, SMTPpro, and the default Magento email system - if you use a different email extension, or are running a new version of one, then it may have issues. If that happens, disable the pickPack email extension, and get in touch.
- Test email sending - check that your PDF is getting attached to the correct emails.
If you have issues, check your Magento email setup first.
Showing 中国/日本の/한국의/русский in PDFs
If you're printing non-Roman characters (ie. accented letters, or picture scripts) in your PDFs you'll need to setup a different font in the config.
pickPack will then attach a font file with the PDF which will then be able to show those characters at the other end.
- Set General > Seeing tofu : ▯? to Yes
This will use a larger font family with more characters in it, which is likely to sort the 'tofu'.
(The 'tofu' is basically characters that aren't in the font which is attached to the PDF or available to your local system)
If you still see tofu then :
- In the left column of the pickPack PDF Editor, find the default font setting
- Choose a specific font to suit the characters you're trying to output
- For these custom fonts, you need to install the optional font pack, which you can find in your Downloads page at Moogento.
- (You need to be on a current pickPack license to have access to that)
- (You need to be on a current pickPack license to have access to that)
Using custom font files
If you're trying to use a custom font, the easiest solution is to replace one of the non-default font files in pickPack with your custom font.
In your pickPack PDF editor you can choose, in the left column, your 'default font'. I'd choose 'Sawasdee'.
Then what you need to do is swap those Sawasdee files for the MS Monaco ones.
You'll find the Sawasdee files here: app/code/Moogento/PickPack/view/adminhtml/web/fonts/sawasdee
Change the name of the Monaco file to match the Sawasdee name, and you should be auto-using that font after a cache clear.
If the correct characters don't appear then you'll need to just find a different font family that can deal with whatever script you're trying to print.