| 1 |
<?xml version="1.0" encoding="utf-8"?> |
| 2 |
<odoo> |
| 3 |
<template id="report_invoice_document" inherit_id="account.report_invoice_document" primary="True"> |
| 4 |
<div id="qrcode" position="after"> |
| 5 |
<div id="myinvois_qrcode" class="d-flex mb-3 avoid-page-break-inside" t-if="o._get_active_myinvois_document().myinvois_document_long_id"> |
| 6 |
<div class="qrcode me-3" id="myinvois_qrcode_image"> |
| 7 |
<t t-set="qr_code_url" t-value="o._generate_myinvois_qr_code()"/> |
| 8 |
<p t-if="qr_code_url" class="position-relative mb-0"> |
| 9 |
<img t-att-src="qr_code_url"/> |
| 10 |
<img src="/account/static/src/img/Odoo_logo_O.svg" |
| 11 |
id="qrcode_odoo_logo" |
| 12 |
class="top-50 start-50 position-absolute bg-white border border-white border-3 rounded-circle" |
| 13 |
/> |
| 14 |
</p> |
| 15 |
</div> |
| 16 |
<div class="d-inline text-muted lh-sm fst-italic" id="qrcode_info" t-if="qr_code_url"> |
| 17 |
<p>Scan this QR Code to<br/>access your invoice |
| 18 |
</p> |
| 19 |
</div> |
| 20 |
</div> |
| 21 |
</div> |
| 22 |
</template> |
| 23 |
|
| 24 |
<!-- Workaround for Studio reports, see odoo/odoo#60660 --> |
| 25 |
<template id="report_invoice" inherit_id="account.report_invoice"> |
| 26 |
<xpath expr='//t[@t-call="account.report_invoice_document"]' position="after"> |
| 27 |
<t t-elif="o._get_name_invoice_report() == 'l10n_my_edi.report_invoice_document'" |
| 28 |
t-call="l10n_my_edi.report_invoice_document" |
| 29 |
t-lang="lang"/> |
| 30 |
</xpath> |
| 31 |
</template> |
| 32 |
</odoo> |