Passa al contenuto
Menu
È necessario essere registrati per interagire con la community.
La domanda è stata contrassegnata
2 Risposte
3367 Visualizzazioni

Hello everybody,

I'am on odoo 10, and I'd like to display 2 headers on my custom report.

One for the first page and the second for the following pages.

Can tell me how to do it?

Thank you.

Best regards

Avatar
Abbandona
Risposta migliore

Check this module which does exactly what you want: https://apps.odoo.com/apps/modules/10.0/report_qweb_element_page_visibility/     

You can use a negative margin-top style in order to place the second-page header on the same vertical position as the first-page header, see the example below:

            <div class="first-page">
                <span t-field="company.header_first_image" t-field-options="{&quot;widget&quot;: &quot;image&quot;, &quot;class&quot;: &quot;padding-small&quot;}"/>
            </div>
            <div class="row col-xs-9 pull-right not-first-page"  style="margin-top:-79px;">
                <span t-field="company.header_not_first_image" t-field-options="{&quot;widget&quot;: &quot;image&quot;, &quot;class&quot;: &quot;padding-small&quot;}"/>
            </div>
Avatar
Abbandona
Autore

Thank you.

I've already tried. in second page is just hide the first header and add the second header after the first one. so i have a lot of blank spaces.

Use a negative margin-top style and you are fine (see my amended example).

@Hilar thanks! I've spent half of a day and about 200 pages of paper until I had fine-tuned my letterheads ;-)