Skip to content

QRCode

v2.101.0

The QRCode widget is used to display QR codes from text or numeric values. It can be used with fields of type char, text, integer, or many2one.

<field name="code" widget="qrcode" />

Widget props

You can customize the appearance of the QR code using the widget_props attribute:

Width

Control the size of the QR code:

<field name="code" widget="qrcode" widget_props="{'width': 300}" />

Border

Control whether to show a border around the QR code:

<field name="code" widget="qrcode" widget_props="{'border': false}" />

Show value

Display the value below the QR code:

<field name="code" widget="qrcode" widget_props="{'showValue': true}" />
https://gisce.net

Many2one fields

When used with many2one fields, the QR code will encode the ID of the related record, and if showValue is enabled, it will display the name of the record:

<field name="partner_id" widget="qrcode" widget_props="{'showValue': true}" />
Partner Name

API

PropertyDescriptionTypeDefaultVersion
nameName of the field to get the value for the QR codestring--
widget_propsExtra properties for the widgetobject--

Widget props

PropertyDescriptionTypeDefaultVersion
widthSize of the QR code in pixelsnumber200-
borderShow border around the QR codebooleantrue-
showValueDisplay the encoded value below the QR codebooleanfalse-