Skip to Content
Meniu
Trebuie să fiți înregistrat pentru a interacționa cu comunitatea.
Această întrebare a fost marcată
1 Răspunde
4511 Vizualizări

Hi Guys,

I am customizing my invoice.

I have created a new xml file with inherited "account.report_invoice_document".

I used xpath to totally replace the section  <table class="table table-condensed">

My problem is that i cannot hide the payment term.

Your kindness is much appreciated.

Thank you guys.

 Here is the code from account.report_invoice_document i was to hide:
           <p t-if="o.payment_term_id">

                <span t-field="o.payment_term_id.note"/>

            </p>



Imagine profil
Abandonează
Cel mai bun răspuns

Hi Charlie,

I've made a pull request to Odoo 11 to allow cleaner xpath expressions on this report (see https://github.com/odoo/odoo/pull/20748 ) as at the moment this is quite tricky / easily to break. For now you would have to xpath to the third <p> element in order to do this. Something along the lines of:

<xpath expr="//p[3]" position="replace"/>

You could also only xpath to the field and just remote the field, without the <p> element:

<xpath expr=//field[@name='payment_term_id.note']" position="replace"/>

Regards,
Yenthe
Imagine profil
Abandonează
Related Posts Răspunsuri Vizualizări Activitate
1
iul. 25
1275
2
iul. 25
1535
1
iul. 25
2573
3
apr. 25
2486
3
apr. 25
3494