summaryrefslogtreecommitdiff
path: root/addons/sale_stock/views/report_invoice.xml
blob: 0e12889a24ec4b0a3089dccd6f1ba8e8b85109d7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
<?xml version="1.0" encoding="utf-8"?>
<odoo>
    <template id="sale_stock_report_invoice_document" inherit_id="account.report_invoice_document">
        <xpath expr="//div[@id='total']" position="after">
            <t t-set="lot_values" t-value="o._get_invoiced_lot_values()"/>
            <t t-if="lot_values">
                <br/>
                <table groups="sale_stock.group_lot_on_invoice" class="table table-sm" style="width: 50%;" name="invoice_snln_table">
                    <thead>
                        <tr>
                            <th><span>Product</span></th>
                            <th class="text-right"><span>Quantity</span></th>
                            <th class="text-right"><span>SN/LN</span></th>
                        </tr>
                    </thead>
                    <tbody>
                        <t t-foreach="lot_values" t-as="snln_line">
                            <tr>
                                <td><t t-esc="snln_line['product_name']"/></td>
                                <td class="text-right">
                                    <t t-esc="snln_line['quantity']"/>
                                    <t t-esc="snln_line['uom_name']" groups="uom.group_uom"/>
                                </td>
                                <td class="text-right"><t t-esc="snln_line['lot_name']"/></td>
                            </tr>
                        </t>
                    </tbody>
                </table>
            </t>
        </xpath>
    </template>
</odoo>