Odoo Help

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 874 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.


About This Community

This platform 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.

Register

Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now

Question tools

1 follower(s)

Stats

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