Skip to Content
Menu
This question has been flagged
1 Reply
2609 Views

Hi all,

I really would like to know more about the report generation pipeline and the differents steps before actual generation: when template inheritance is made, when qweb tags (<t>) and attributes are parsed and so on. Details are welcome. Also, is the pipeline different when doing HTML or PDF generation ? 

I am on Odoo 8, by the way.

Avatar
Discard
Author

@Axel Mendoza, yes I have read the source code but I couldn't find what I expected. What drove me to ask this question is the following statement: there is not a clean way to link an external css file to one specific report (not others). I tried in many way even by using JavaScript (add a link in the head tag) but it doesn't work. I think that wkhtmltopdf doesn'nt execute my JS code. To insert style to a report, I had to put it between style tag, which I find very ugly. Ok, I read the Github issue about that and considerations about future intergration of web assets and also "pseudo" namespaces for each module reports. But I find too badthe fact that the usual web for web developer (link tag in head) doesn't work. But I agree, it is not really a question nor an answer, but rather an opinion.

Best Answer

Is the same for HTML or PDF. For those specific details and also not a very explicit question I suggest that you need to read the source code of the report module and the qweb rendering template engine at base module. QWEB Reports are just QWEB templates rendering as HTML and for PDF files they just use the lib WKHTMLTOPDF to convert it into a PDF file. But the details are on the source code

Avatar
Discard