Label Printing

Mise à jour le 18 septembre 2026·

Introduction #

The label printing system offers the ability to send a raw message to a network printer on demand. These messages can be sent from any module, provided appropriate configuration is in place.

Configuration #

ioi Module #

To enable the label printing function in a module, activate the Manual labelling setting:

Once this setting is activated for a module, the following button becomes available:

ioi Label Paper Format #

Each label is associated with a paper format. The label printer is also linked to a paper format, allowing compatibility testing before printing.

The numeric values in the Width and Height fields do not influence actual printing but are important for a later feature described in this document.

ioi Printer Model #

Each printer is associated with a model that specifies characteristics such as brand, model, and printing technology. For the feature described in this document, the ZPL2 printing technology is used.

ioi Printer #

The following information is filled in for each label printer:

  • Printer model: The printing technology of this model must be ZPL2.
  • IP address: The ioi backend launches the printing.

Info

This means that the IP address must be accessible via the ioi server.

    • Port: By default, the port is 9100.
    • Paper format: A test print can be performed to ensure that the printer’s paper format matches the label’s.

Info

If the printer’s paper format does not match the label’s, an error message prompts the user to change the label before proceeding with the print or cancelling the action.

  • ZPL to PDF: This option allows ZPL labels to be printed as PDFs. The label content is sent to an API responsible for the conversion.

Info

This API has usage limitations. It is mainly intended for testing purposes. https://labelary.com/service.html#limits

Attention

The numeric dimensions from ioi Label Paper Format will be used in this API. Don’t forget to enter them!

ioi Label Format #

This module is dedicated to creating labels.

Main options: #

  • Multiple printing: Multiplication factor for printing (default: 1)
  • Label Paper Format: Paper format used for the label
  • For Doctype: Indicates the document type for which the label is intended (Item, Address, Customer, etc.)
  • Site id: If the filter is enabled and the site is specified, this label will only be available for users on that site.
  • Division id: If the filter is enabled and the division is specified, this label will only be available for users in that division.
  • Filter condition: The condition must be written in Python format and return a boolean value. The src_doc object allows access to the calling document’s properties → src_doc.ioistatus

Example: frappe.utils.cint(src_doc.ioistatus) == 0 # test document status

From doctype : #

A single label can be called from different document types (doctypes). This table allows specifying from which document type the label can be called.

  • Doctype: Name of the calling document type.
  • Type: Field type of the document (Document field, Detail field)
    • The field type determines how the link will be established with the For DocType parameter. The aim is to link a field of the calling document to a document of the type specified in For DocType.
  • Field name: Displays compatible fields based on the selected field type.
    • If Document field, it displays the calling document’s Link fields that link to the For DocType.
    • If Detail field, it displays the Table-type fields of the calling document that contain at least one Link field pointing to the For DocType.
    • In this case, the Child field name field will only display Link-type fields of the table’s doctype that link to the For DocType.
  • Quantity field name: Optional, this field allows using the value of the mentioned field as the number of labels to print. The label’s multiplication factor is taken into account.
  • Condition: The condition must be written in Python format and return a boolean value. The following objects are available:
    • master: Access to the document of type For DocType.
    • src_doc: Access to the document that triggers the printing. This document is either the calling document or a row in a table of the calling document, depending on the selected type.
    • src_p_doc: If the type is Detail field, src_doc is the row, and src_p_doc is the parent document.

Raw #

Raw format of the label. As with conditions, it is possible to include variables from various sources (master, src_doc, src_p_doc, system).

Cette page vous a-t-elle aidé ?