diff --git a/addons/hr_expense/static/src/components/qrcode_action.js b/addons/hr_expense/static/src/components/qrcode_action.js new file mode 100644 index 00000000000..3b6c270ec27 --- /dev/null +++ b/addons/hr_expense/static/src/components/qrcode_action.js @@ -0,0 +1,24 @@ +/** @odoo-module */ + +import { registry } from "@web/core/registry"; +import { Component, xml } from "@odoo/owl"; + +const actionRegistry = registry.category("actions"); + +class QRModalComponent extends Component { + setup() { + this.url = _.str.sprintf( + "/report/barcode/?barcode_type=QR&value=%s&width=256&height=256&humanreadable=1", + this.props.action.params.url); + } +} + +QRModalComponent.template = xml` +