PDF Invoices: Troubleshooting
Troubleshooting the PDF Invoices module for OXID eShop 7.x: missing tab, PDF creation, missing attachment, integrity errors, logo, bank details and number gaps.
PDF Invoices: Troubleshooting
Live Demo: Try this and other plugins live — no installation, no risk: demo.markus-michalski.net
This documentation always describes the latest published version.
Errors of the module are logged through the OXID logger. Most messages start with [mmd_pdfinvoice]. The setting "Enable Debug Logging" is intended for additional flow messages of the module. Error messages are always logged, independent of it.
The "PDF Invoice" tab is missing in the order
Symptom: The order details have no "PDF Invoice" tab.
- Check that the module is activated (Extensions > Modules).
- Clear the cache:
vendor/bin/oe-console oe:cache:clear. - Deactivate and re-activate the module so the menu configuration is read again.
Message "Error creating invoice."
Symptom: This message appears when you click "Create Invoice".
- Search the OXID log for entries with
Invoice creation failedorPDF generation failed. They contain the cause. - Check that the web server user can write to the storage path (default
source/export/invoices). - Check that the web server user can write to
source/tmp/dompdf. - Check that the tables
mmd_pdfinvoiceandmmd_pdfinvoice_seqexist. They are created on activation.
The invoice is not attached to the order email
Symptom: The order confirmation arrives without a PDF.
Check in this order:
- Email Attachment: Is the setting on "Do not attach", or does it not match the recipient? "Customer only" does not attach the invoice to the email to the shop owner and vice versa.
- Auto-generate: If the option is off and the order has no invoice yet, nothing is attached. Create the invoice in the admin area or enable the option.
- Log: Search the OXID log for
Failed to attach invoice PDF to email. Attaching then fails, the order email is still sent. - Cache: Clear the cache after changing settings.
Download or attachment fails (integrity check)
Symptom: The admin shows "Error downloading invoice.", the log contains PDF integrity check failed or PDF file not found.
Cause: When reading the PDF file, the module compares its SHA-256 hash with the stored value. The file was modified, replaced or deleted.
Solution: Click "Regenerate PDF" in the "PDF Invoice" tab. The module re-creates the PDF from the snapshot, replaces the file and stores the new hash.
Message "An invoice already exists for this order."
There is exactly one invoice per order and shop, enforced by a unique key in the database. The module cannot create a second invoice.
"Regenerate PDF" renders the PDF from the order's stored snapshot. It can therefore only pick up changes to master data, logo and template. It does not correct wrong order data (address, items, prices) in the snapshot.
Logo is not displayed
- The path must be given relative to
out/pictures/. - The file must actually exist under
out/pictures/, otherwise no logo is printed and the shop name appears instead. - With an empty field the module uses the shop logo from the shop settings. Check that it is also located under
out/pictures/. - After changing the logo click "Regenerate PDF"; invoices that already exist do not change on their own.
Wrong bank or company details on the invoice
The details in the header, the footer and the payment block come from the shop master data in the OXID admin (Master Settings > Core Settings > Master Data). They are read again every time a PDF is created. After changing the master data this only affects new invoices and regenerated PDFs.
Gaps in the invoice numbering
Cause: The invoice number is assigned before the PDF is created and stored. If creation or storage fails afterwards, the number is used up and a gap appears because no invoice was saved for that order.
Note: With consecutively numbered invoices, check the log for the error behind it and document such gaps in your bookkeeping.
The PDF invoice is not in English
The invoice template has its texts hard-coded in German, regardless of the shop language. See Template and Variables.
The invoice email from the admin is not sent
Symptom: "Email sending failed".
- Check that the order has a billing email address. Without an address nothing is sent.
- Check that the shop's normal email delivery works (sender address from the shop master data, mail configuration).
- Search the OXID log for
Invoice email failed.
Direct debit invoice shows no customer IBAN
The customer's bank details only appear on the invoice if the payment method is oxiddebitnote and the bank details are stored in the order. If they are missing, the IBAN line in the SEPA block stays empty.