I've generate some PDF invoices using a template as a background (also a PDF generated using Word). In some computers the fields doesn't get writen, they show an empty template. On other computers the PDF is generated correctly. The PDF files generated on both machines are the same size, but one has the fields rendered correctly and on the other appear blank, the info of the fields is on the file but written differently (inside). Sometimes an empty PDF is generated on computers with outdated browsers or OS, and sometimes on computers with browsers and OSes up to date. When a header is added, the text in the header is always writen, but the fields don't. I'm missing something? The template must have some requirements?
In mobile, the PDF is rendered correctly if viewed on safari browser or chrome browser for example, but empty on gmail app browser, or in other pdf viewers.

Comments

vegansupreme’s picture

The PDF is being generated server-side, so it should be identical regardless of client browser platform. That said, not all PDF viewers are equal.
Are you able to save a PDF generated on a platform that doesn't work right, and open it on a platform that does?
Can you tell if the PDF template background is transparent?
Can you save the template PDF to make it compatible with lower versions of PDF reader?

edmarmota’s picture

I've narrowed the problem, and the view that generates the PDF has a relationship filter on user id. When I delete that relationship the PDF is generated correctly on any browser (minus the user info).
What could cause the behaviour?

vegansupreme’s picture

Since you mentioned User, any chance there's a permission issue? I've used relationships before without problem—though I don't think I've used a User relationship.

killua99’s picture

Status: Active » Closed (outdated)