Reputation: 2186
How add custom text in inherit qweb?
For example in Sale/view/report_saleorder.xml
below class="oe_structure" i need one table
<p t-field="doc.note" />
<p t-if="doc.payment_term_id.note">
<span t-field="doc.payment_term_id.note"/>
</p>
<p t-if="not doc.payment_term_id and doc.partner_id.property_payment_term_id">
<span t-field="doc.partner_id.property_payment_term_id.note"/>
</p>
<p id="fiscal_position_remark" t-if="doc.fiscal_position_id and doc.fiscal_position_id.note">
<strong>Fiscal Position Remark:</strong>
<span t-field="doc.fiscal_position_id.note"/>
</p>
<div class="oe_structure"/>
<xpath expr="???" position="???">
<table><tr><td>CUSTOM TEXT</td></tr></table>
</xpath>
Upvotes: 0
Views: 242
Reputation: 3378
I am not sure if the above xml is the whole report however you could use something like this.
<xpath expr="//div[@class='oe_structure'][last()]" position="after">
<!-- YOUR TABLE HERE -->
</xpath>
This assumes this is the last instance of oe_structure in the xml you are inheriting from.
Upvotes: 2