Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

0

How do you add a new report paper format in a module? (using xml)

By
E.M.
on 10/17/15, 1:07 PM 491 views

Hi, I would like to define a new report paper format for a custom report.

I know how to link a report with a specific report paper, but I would like the paper format to be created by the module and not through the GUI. 

Is there somewhere where I could find an example or could someone share how to achieve it?

Thanks,

1
Shawn Varghese
On 10/18/15, 2:09 AM

You could try using the existing paper definitions and make your own based on them. In the reports module, in the data directory, you can find the report_paperformat.xml .


<record id="paperformat_euro" model="report.paperformat">
<field name="name">European A4</field>
<field name="default" eval="True" />
<field name="format">A4</field>
<field name="page_height">0</field>
<field name="page_width">0</field>
<field name="orientation">Portrait</field>
<field name="margin_top">40</field>
<field name="margin_bottom">23</field>
<field name="margin_left">7</field>
<field name="margin_right">7</field>
<field name="header_line" eval="False" />
<field name="header_spacing">35</field>
<field name="dpi">90</field>
</record>


Maybe this could help.


Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)

Stats

Asked: 10/17/15, 1:07 PM
Seen: 491 times
Last updated: 10/18/15, 6:48 AM