Ir al contenido
Menú
Se marcó esta pregunta
1 Responder
216 Vistas

Bonjour, 


J'aimerais modifier le terme "Facture Proforma" en "Devis", merci beaucoup pour votre aide. 


Dominique 

Avatar
Descartar
Mejor respuesta

Hi,


Try the following code,


<odoo>

    <template id="report_invoice_document_inherit_estimate" inherit_id="account.report_invoice_document">

        <xpath expr="//h2/span[t-else='']" position="replace">

            <span t-if="not proforma"></span>

            <span t-else="">Estimate</span>

        </xpath>

    </template>

</odoo>


OR


<odoo>

    <template id="report_invoice_document_inherit_estimate" inherit_id="account.report_invoice_document">

        <xpath expr="//h2/span[t-else='']" position="replace">

            <span t-else="">Estimate</span>

        </xpath>

    </template>

</odoo>


* Put this inside your custom module under views/report_invoice_estimate.xml.

* Add that file to your module’s __manifest__.py → data.

* Upgrade your module.

* Now, whenever you print a proforma, the header will show Estimate instead.


You can achieve the same result using Odoo Studio customization:


    Open Studio → Go to Reports.


    Select the invoice report (Proforma/Invoice template).


    Click on the heading element (PROFORMA INVOICE) in the report preview.


    Replace the text with “Estimate” (or whatever label you want).


    Save and close Studio.


This way, the change is applied without touching code.


Hope it helps


Avatar
Descartar