← Back to team overview

openerp-community team mailing list archive

Re: report_webkit future



- "server/report" is the rml egine with it's funny [[ syntax ]] 6460 line of code
- "report_webkit" is the c2c jinja2 report engine 611 line of code
- "report" is the new v8 qweb-based report engine 497 line of code

Here is my plan:


we keep "server/report" and "report_webkit" unchanged, but every report in our addons are converted to qweb.


we remove "server/report" and "report_webkit" from our repository, "report_webkit" will be moved to a community repo (like we do for every deprecated module).

So you should adapt your "report_webkit" reports to the new "report" engine, the main difference is to use qweb templating instead of jinja2. The principal advantage of using qweb instead of jinja2 is the modularity (like forms views). Qweb directives are xml-attributes (only 7 attributes that you need to learn) so a qweb template is easily extensible using the built in xpath extention mecanism of openerp (exactly like form views).

In pratice you can now easily extend sale order lines, adding or removing a field, change the style, ... Reports in openerp was the ONLY non-modular component, it's a huge leap forward.

OpenERP Enterprise customer can ask our migration services to convert their report for a very small fee (part of our custom code migration option).

Converting a "report_webkit" report to a "report" is very easy the code doesnt change, you only need to adapt the template from one syntax to an other one. I think it could almost be automated.

An other interresting change is that report are now REST as every report has an url like:


and options can be provided


the above controller output the html version of the report, for the pdf version you can use


This controller simply loads the first one and pass it trough wkhtml2pdf and returns the pdf.

Please TEST it before commenting, the branch is trunk-qweb-report2, and trunk-qweb-report.

I would like to thank c2c for the "report_webkit" module as it really paved the way to the switch from RML to HTML/CSS, and to the quick generation of pdf using wkhtmltopdf. We keep those feature in "report". We unifed openerp template engine into qweb an xml-friendly-extensible template engine (and therefore modular like the rest of openerp) that is now used everywhere.

On 02/18/2014 09:27 AM, Nicolas Bessi wrote:
Dear community,

With the approaching release of V8, I'm starting to have questions about the
future of the Webkit reports.

*QWeb and Webkit*
First of all there seems to be a lot of confusions between QWeb reports and
Webkit reports.

Qweb reports and Webkit reports are separated reports engines even if they
both rely on similar concept.

They both allows you to develop at set of report using an HTML based template
But they have some major differences.

AFAIK Qweb reports are view based reports that offer the same flexibility than
standards OpenERP views, (inherit, groups, xpath, translation, etc).

Webkit reports rely on an external library (wkhtmltopdf) to generate PDF from
HTML are generated using mako/jinga templates. Webkit reports were created to
desing complex layout (like ESR payment slip) and render huge report
(thousands of pages) without needed a huge machinery.

My opinion is that both report engine are complementary at that time.

*Future of Webkit reports*

I have not heard that report_webkit will be deprecated and there are still in
code base.
Camptocamp will continue to maintain existing webkit reports (especially
financial report) but may port to Qweb report that are a better fit for this
technology (PO, SO, etc.)

We will also continue to provide enhancement and support to report_webkit for
next the release.

That said it is not impossible at middle term when we have more feedback on
Qweb report to have convergence of both engines.



Follow ups