Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Customizing templates #3

Open
j3k0 opened this issue Aug 29, 2016 · 3 comments · May be fixed by #21
Open

Customizing templates #3

j3k0 opened this issue Aug 29, 2016 · 3 comments · May be fixed by #21

Comments

@j3k0
Copy link
Contributor

j3k0 commented Aug 29, 2016

Is it possible to customize templates using this docker image? I'm new to Invoiceplane, but it seems like the templates are not in the persisted volume, so it might not be possible?

@sameersbn
Copy link
Owner

@j3k0 I have not tried customising templates. If you have relavant information/examples please share. I would like to support it.

@j3k0
Copy link
Contributor Author

j3k0 commented Oct 23, 2017

Sure. Taken from https://wiki.invoiceplane.com/en/1.0/templates/using-templates

All PDF templates can be found in the following folders of the application:

/application/views/invoice_templates/pdf for invoices
/application/views/quote_templates/pdf for quotes

You can select which templates should be used in the system settings for either Invoices or Quotes. You can find the select boxes below the headline "Templates". Simply select the template, save and the template will be used for the next quote or invoice.

It's not mentioned in the doc, but web templates (for "guest web preview") are in application/views/invoice_templates/public/ (resp. quote)

Those directories can't be "simple" volumes, as they initially contain the default templates:

/var/www/invoiceplane# ls application/views/invoice_templates/pdf/
InvoicePlane - overdue.php  InvoicePlane - paid.php  InvoicePlane.php

So maybe the approach is to make a volume at a different location, like /templates and link files from the volume /templates/invoice/pdf to /var/www/invoiceplane/application/views/invoice_templates/pdf (and family) in the entrypoint.sh script.

The drawback being that adding a new template will require to restart the container...

@MilanDeruelle
Copy link

I've got the same problem. This issues makes the dockerfile more or less unusable, there is little point in using invoiceplane if its not possible to customize templates.

I tried to --volume /var/www/invoiceplane/application/views/ to a folder on my host but I get php errors saying "file not found" when using invoiceplane. Not sure why it is not working - would be glad for any ideas on how to approach this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants