Initial commit: Odoo 18.0-20251222 extra-addons
This commit is contained in:
58
account_invoice_triple_discount/report/invoice.xml
Normal file
58
account_invoice_triple_discount/report/invoice.xml
Normal file
@@ -0,0 +1,58 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<odoo>
|
||||
<template
|
||||
id="report_invoice_document"
|
||||
inherit_id="account.report_invoice_document"
|
||||
priority="100"
|
||||
>
|
||||
<xpath expr="//t[@t-set='display_discount']" position="attributes">
|
||||
<attribute name="t-value">False</attribute>
|
||||
</xpath>
|
||||
<xpath expr="//t[@t-set='display_discount']" position="after">
|
||||
<t
|
||||
t-set="discount_class"
|
||||
t-value="'text-end %s' % ('d-none d-md-table-cell' if report_type == 'html' else '')"
|
||||
/>
|
||||
</xpath>
|
||||
<xpath expr="//th[@name='th_discount']" position="attributes">
|
||||
<attribute name="style">visibility: hidden;</attribute>
|
||||
</xpath>
|
||||
<xpath expr="//th[@name='th_discount']" position="after">
|
||||
<th
|
||||
name="th_discount1"
|
||||
t-if="display_discount"
|
||||
t-att-class="discount_class"
|
||||
>
|
||||
<span>Disc.1 %</span>
|
||||
</th>
|
||||
<th
|
||||
name="th_discount2"
|
||||
t-if="display_discount"
|
||||
t-att-class="discount_class"
|
||||
>
|
||||
<span>Disc.2 %</span>
|
||||
</th>
|
||||
<th
|
||||
name="th_discount3"
|
||||
t-if="display_discount"
|
||||
t-att-class="discount_class"
|
||||
>
|
||||
<span>Disc.3 %</span>
|
||||
</th>
|
||||
</xpath>
|
||||
<xpath expr="//td[span[@t-field='line.discount']]" position="attributes">
|
||||
<attribute name="style">visibility: hidden;</attribute>
|
||||
</xpath>
|
||||
<xpath expr="//td[span[@t-field='line.discount']]" position="after">
|
||||
<td t-if="display_discount" t-att-class="discount_class">
|
||||
<span class="text-nowrap" t-field="line.discount1" />
|
||||
</td>
|
||||
<td t-if="display_discount" t-att-class="discount_class">
|
||||
<span class="text-nowrap" t-field="line.discount2" />
|
||||
</td>
|
||||
<td t-if="display_discount" t-att-class="discount_class">
|
||||
<span class="text-nowrap" t-field="line.discount3" />
|
||||
</td>
|
||||
</xpath>
|
||||
</template>
|
||||
</odoo>
|
||||
Reference in New Issue
Block a user