Skip to Content
Menu
This question has been flagged
2759 Views

One of my models generates pdf files as attachments when it is created. When I try to create that model from demo_data.xml odoo stops during the creation of the pdf file (at the wkhtmltopdf subprocess call). When I create the model in the UI it works fine. I suspect that is has to do with the active user being the OdooBot (__system__) during the installation of demo data, but that is just a guess.

Is it possible to generate pdf:s during installation of demo data? If not, what could I do to add pdf attachments with the demo data?


I am using Odoo 12, and Wkhtmltopd 0.12.5 

Avatar
Discard

you can use the similiar code with some modifications that generates quotations/invoices over xmlrpc to generate those missing pdfs.

or you can add something to post_hooks to handle generation