Перейти к содержимому
Меню
Чтобы взаимодействовать с сообществом, необходимо зарегистрироваться.
Этот вопрос был отмечен
1 Ответить
30018 Представления

I want to edit the default header & footer of the Invoice PDF reports. The view of the report is calling web.external.layout for header & footer when I try to make changes to the web.external.layout then it is not accepting the changes.

View of Invoice PDF reports is as below.

========================================

<?xml version="1.0"?>
<data inherit_id="account.report_invoice_document">
<xpath expr="//t[@t-call='web.external_layout']" position="replace">
<t t-call="web.external_layout">
<t t-set="o" t-value="o.with_context({'lang': lang})"/>

======================================

it calling web.externa_layout for header & footer.

I really don't know whether it is for header/footer or not. I want to edit the default header & footer and don't want to create a new one.

Currently, I am using Odoo V12.



Аватар
Отменить
Лучший ответ

Hi,

Please try this,

<template id="external_layout_header_inherit_cr" 
            inherit_id="report.external_layout_header">
            <xpath expr="//div[@class='header']" position="replace">
                <div class="header">
                    <!-- code -->
                </div>
            </xpath>
        </template>
        <template id="external_layout_footer_inherit_cr" 
            inherit_id="report.external_layout_footer">
            <xpath expr="//div[@class='footer']" position="replace">
                <div class="footer">
                    <!--  code -->
                </div>
            </xpath>
        </template>
Aswini - iWesabe


Аватар
Отменить
Related Posts Ответы Просмотры Активность
1
апр. 15
4695
4
июл. 20
18663
1
окт. 18
8490
PDF reports Решено
5
июл. 25
2253
Wrong PDF Format Решено
2
мар. 24
2773