Custom fields PDF

Hello,
I am looking for a way to add a custom text field to the PDF.
I’m in desperate need of help. I do not know how to add it. I have read the FAQ and documentation but with no success in my specific case.

What i want to get done. is to add a Custom field for the Invoice. and that it will be printed on the PDF.
A company name and a adressed to field.

If there are multiple topics regarding this matter i apologize but i need a solution asap.

Thank you.

https://wiki.invoiceplane.org/en/1.5/settings/custom-fields

Not helping. I already said that i’ve read those articles. But thanks.

Perhaps if you say what you have tried and how it is not working, it will be easier for people assist. Simply saying you can’t could be due to any number of things. We can only guess to what you have done and the results of.

Sorry for my jackass response. i was kind of frustrated as you can tell.

I got it working.

Thanks.

Well done @NelsCon.

Please write on how you achieved this. I am sure it will help others in the future,

Ok, My explaining skills are horrible so bare with me.
I wanted to put a custom field displayed on the PDF when filled in. So I went ahead and looked for the file that is responsible for the PDF layout.


I created a custom field entry in the web interface in the Invoice table. and I wanted to put that in the client name area when filled in.

The file is in application/views/invoice_templates/pdf/InvoicePlane.php
If the field in the invoice table is filled in > echo the input of custom field Tav on the pdf at the client area.

https://pastebin.com/embed_iframe/uTHxAD6T

If someone can make my explanation make more sense please do.

1 Like