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

Hello,

How can we get in a same report some page with portrait orientation and some other page in landscape orientation?

Thank you for your help.

Avatar
Discard
Best Answer

Hello Henintsoa Ariel RATOLOJANAHARY,

Odoo default is not supporting this functionality but yes, you may still get it by customising reports.


You must utilise two paper formats for that: one for landscape orientation and one for portrait orientation.

Please find below code for Paperformat it may help you,

Thanks & Regards,
Email: odoo@aktivsoftware.com
Skype: kalpeshmaheshwari

Avatar
Discard

<record id="paperformat_portrait" model="report.paperformat">
<field name="name">Paperformat Portrait</field>
<field name="default" eval="True"/>
<field name="format">A4</field>
<field name="orientation">Portrait</field>
<field name="margin_top">45</field>
<field name="margin_bottom">50</field>
<field name="margin_left">7</field>
<field name="margin_right">7</field>
<field name="header_line" eval="False"/>
<field name="header_spacing">40</field>
<field name="dpi">90</field>
</record>

<record id="paperformat_landscape" model="report.paperformat">
<field name="name">Paperformat Portrait</field>
<field name="default" eval="True"/>
<field name="format">A4</field>
<field name="orientation">Landscape</field>
<field name="margin_top">45</field>
<field name="margin_bottom">50</field>
<field name="margin_left">7</field>
<field name="margin_right">7</field>
<field name="header_line" eval="False"/>
<field name="header_spacing">40</field>
<field name="dpi">90</field>
</record>

When you are finished, use the t-call command to call this format depending on conditions.

Author

Thank you. i will try and get back to you.

Related Posts Replies Views Activity
1
Mar 24
366
1
Jun 17
8456
0
Nov 15
3282
1
Jun 19
4624
0
Oct 24
118