many2many_uom_tags
New in Odoo 19, many2many_uom_tags is the tags widget with unit awareness: its dropdown shows each unit of measure alongside what it converts to for the product at hand.
| Technical name | many2many_uom_tags |
|---|---|
| Field types | many2many |
| Views | form |
| Module | uom, auto-installed with Inventory, Sales, and Purchasing |
| Used in core | 2 occurrences in the product module, both on the product template form's uom_ids |
| Versions | Odoo 20.0, Odoo 19.0 |
| No-code setup | No. Set in XML; Studio's widget list does not offer it. |
| Alternatives | many2one_uom, many2many_tags, many2many_checkboxes |
What the UoM tags field does
What this means for your team
Supported options in Odoo 19
| Option | Type | What it does |
|---|---|---|
product_field | field name | Names the many2one, to product.product or product.template, whose reference unit anchors the conversion hints. Unnecessary on product views, where the record itself is used. A non-product field makes the component throw at setup.(default: product_id)(since Odoo 19.0) |
quantity_field | field name | Names the float whose value scales every hint, so the dropdown shows totals rather than per-unit ratios. Declared with availableTypes many2one in the source, which is a mislabel; it reads a numeric field.(default: product_uom_qty)(since Odoo 19.0) |
Both additions are declared with availableTypes: ["many2one"], and for quantity_field that is wrong. The quantity field it reads is a float like product_uom_qty. The mistyped declaration only affects tooling that filters selectable fields by type; at runtime the widget reads whatever field name you give it. The same quirk exists on the sibling many2one_uom widget.
Working examples
How the conversion hints are computed
Version compatibility
| Version | Status | Notes |
|---|---|---|
| Odoo 20.0 | In development | Not released. Rebase onto plain tags, color and edit_tags options dropped, and precision-based rounding visible on the development branch; see below. |
| Odoo 19.0 | Verified | Verified against the shipped source. Born with the packaging-as-units rework. |
| Odoo 18.0 | Not available | Widget does not exist; packaging used product.packaging records. |
| Odoo 17.0 | Not available | Widget does not exist. |
| Odoo 16.0 | Not available | Widget does not exist. |
Upgrade note. The widget arrived in 19.0 as part of the packaging rework that introduced uom_ids itself, so there is no earlier equivalent to migrate from. Odoo 18 and below model packaging as product.packaging records with ordinary widgets.
What is changing in Odoo 20
Common problems and fixes
| Symptom | Cause and fix |
|---|---|
| Error naming the widget and a product model at load | The component throws when product_field points at a non-product relation and the view's model is not a product either. Set product_field to a many2one targeting product.product or product.template. |
| No conversion hints in the dropdown | No product resolved yet, the product field is empty, or the option points at the wrong field. Pick the product first; hints are computed against its reference unit. |
| Hints show strange totals | quantity_field is scaling them, by design, using its current value. Point quantity_field elsewhere or remove it to get per-unit ratios. |
| Users create junk units from typed text | Inline quick-create is inherited from the tags family and on by default. Add no_quick_create, as core's product form does. |
| Clicking a pill opens the unit form | edit_tags is set, as in core's usage; that is its purpose. Remove edit_tags if pills should be inert; note the option disappears on the development branch. |
UoM tags field vs the alternatives
| Widget | Best for | Key difference |
|---|---|---|
many2many_uom_tags | Allowed packagings on products and unit sets needing ratio context | Tags dropdown with per-product conversion hints |
| many2one_uom | The single unit on an order or move line | One value, paired with product and quantity fields the same way |
| many2many_tags | Any other tag-like relation | Same pills without unit awareness or conversion hints |
| many2many_checkboxes | Short fixed unit lists | Every option visible as a checkbox, no search, no hints |
Frequently asked questions
What does the many2many_uom_tags widget do?+
How does the widget know which product to convert against?+
What is quantity_field for?+
Which tags options work on many2many_uom_tags?+
Why are same-category units listed first in the dropdown?+
Is many2many_uom_tags available before Odoo 19?+
What changes in Odoo 20?+
Migrating packagings to Odoo 19's unit model?
The packaging rework behind this widget touches products, stock rules, and every order line that mentions a unit. We plan and execute Odoo migrations, data model included, and untangle UoM structures that grew organically over the years.
Book a free consultation