In the visual editor
Add a Barcode / QR block (in Content) and set:- Type: Barcode (Code 128) or QR code.
- Encodes: Order name (#1042), Order number (1042), Document number, or Custom. With Custom, write the Text to encode, with order values like
SO-{{ order_number }}.
In code
Barcodes
- The first option is the barcode type. Without one, it’s Code 128.
- Two more numbers set the printed width and height in millimetres, for example 60 × 12 mm for a shipping label.
code128, code39, code39ext, code93, ean13, ean8, upca, upce, itf14, interleaved2of5, codabar and msi.
QR codes
- The first option is the error correction level:
L,M(the default),QorH. Higher levels survive more damage but make a denser code. - The second is the size in pixels (default 96).
Good to know
- An empty value draws nothing, so products without a barcode simply have none.
- A value the barcode type can’t hold (for example letters in an EAN-13) draws a small red error box with the reason, so you see it in the preview.
- A Document number barcode prints nothing until the document has a number.
{{ order_status_url }}exists for online orders only.