Skip to main content
iVentureTeam

upgrade_selection

A settings dropdown that only works on Enterprise. On Community it opens the upgrade dialog and, when that closes, puts the value back to a hardcoded default.

Siddharth JambukiyaSiddharth JambukiyaOdoo Techno-Functional Consultant
August 27, 2026Updated August 28, 20264 min read
Technical nameupgrade_selection
Field typesselection
Viewsform
Modulepos_self_order, Point of Sale self ordering
Used in core1 occurrence, a Point of Sale configuration setting
VersionsOdoo 20.0, Odoo 19.0, Odoo 18.0, Odoo 17.0
No-code setupNo. It is a settings widget tied to an edition check
Alternativesselection, upgrade_boolean, radio

What the upgrade selection does

Some settings in Odoo exist in both editions but only function in Enterprise. Hiding them entirely on Community leaves users wondering whether the feature exists; showing them working leads to a setting that silently does nothing.

The convention Odoo uses is to show the control and intercept the change. This widget applies that to a selection: on Enterprise it is an ordinary dropdown, and on Community choosing a different value opens the upgrade dialog rather than applying it.

Its source comment states the intent plainly, that it is meant for configuration settings and shows an upgrade popup when the selection changes. The wrinkle is what happens afterwards.

What this means for your team

Edition-gated settings are a product decision before they are a technical one, and the pattern here is the honest version of it: the option is visible, its unavailability is explained at the moment of interest, and the path to enabling it is offered. That converts better than hiding the feature and confuses less than letting it fail.

For anyone building on Community, the practical note is that this control cannot be made to work by changing the view. The check reads the edition from the build information, so the dialog appears regardless of what the setting is set to elsewhere.

Supported options in Odoo 19

The widget declares no options of its own and inherits the selection widget's descriptor. Its behavior is decided from the edition rather than from configuration. Read from upgrade_selection_field.js, Odoo 19.0.

OptionTypeWhat it does
placeholder_fieldfieldInherited from the selection widget. Shows another field's value as a hint while this one is empty.

The reset value is hardcoded. When the upgrade dialog closes, the widget writes a specific literal value back into the input rather than restoring whatever was previously selected. That value is written into the source for this particular Point of Sale setting, which makes the widget non-portable to another selection.

Working examples

The usual usage

<field name="self_ordering_mode"
       widget="upgrade_selection"/>

On Enterprise this is a normal dropdown. On Community, changing it opens the upgrade dialog.

The plain selection

<field name="self_ordering_mode" widget="selection"/>

No edition check, and the setting applies wherever it is chosen.

The boolean equivalent

<field name="some_flag" widget="upgrade_boolean"/>

The same pattern for a checkbox, and the widget this one mirrors.

The hardcoded value it resets to

The change handler is the whole widget. It checks a flag derived from the client-side build information and, when that says the database is not Enterprise, opens the upgrade dialog and returns without applying the change. On Enterprise it calls through to the standard handler.

The dialog is opened with a close callback, and that callback is where the widget's one quirk lives: rather than restoring the previously selected value, it assigns a specific literal string to the input element. That string is the default mode for this particular Point of Sale setting, written into the source.

Two consequences follow. Reusing the widget on a different selection would reset that field to a value that means nothing to it, and even on the intended field the reset is to the default rather than to whatever the user had before.

The edition check itself is worth noting for what it is not: it reads client-side build information rather than asking the server, so it is a presentation decision and not a security boundary. Whatever actually enforces the feature lives elsewhere.

Version compatibility

VersionStatusNotes
Odoo 20.0In developmentNot released. Byte-identical to Odoo 19 on the development branch.
Odoo 19.0VerifiedVerified against the shipped source. Identical to Odoo 18.
Odoo 18.0VerifiedIdentical behavior.
Odoo 17.0VerifiedFirst version.
Odoo 16.0Not availableWidget does not exist.

Upgrade note. The widget arrived in Odoo 17 and the Odoo 18 and Odoo 19 files are identical, so nothing needs attention in views. Its behavior depends on the edition rather than the version.

What is changing in Odoo 20

Odoo 20 is expected at Odoo Experience in Brussels, 24 to 26 September 2026. The development branch is unstable and this may still change; we re-verify this page after the release.

Byte-identical. The file on the development branch matches Odoo 19 exactly, including the hardcoded reset value.

Common problems and fixes

SymptomCause and fix
The upgrade dialog appears on every changeThe database is not Enterprise, which is exactly what the widget checks. Expected. The setting cannot be enabled from the view.
The value resets to something I did not chooseThe close callback writes a hardcoded literal rather than restoring the previous value. Expected for this setting; the value is written into the source.
Nothing happens on EnterpriseIt behaves as a normal selection there, so the change simply applies. Nothing to fix.
Reusing it resets my field oddlyThe hardcoded reset value belongs to the Point of Sale setting it was written for. Copy the widget with your own reset value, or use the boolean equivalent.
Missing widget errorThe self-order module is not installed in that database. Install it, or use the plain selection widget.
The check can be bypassedIt reads client-side build information and is a presentation decision, not enforcement. Rely on server-side enforcement for anything that matters.

Upgrade selection vs the alternatives

WidgetBest forKey difference
upgrade_selectionEdition-gated settings shown as a dropdownOpens the upgrade dialog on Community and resets the input to a hardcoded value
selectionAny ordinary selectionNo edition check and no dialog
upgrade_booleanThe same pattern on a checkboxA boolean rather than a dropdown
radioShort choice listsRadio buttons, again with no gating

The boolean equivalent is the widget to use for a checkbox rather than a dropdown. For a setting that should simply be hidden on Community, a group or an invisible expression is cleaner than an interception. And for a genuine feature gate, the enforcement belongs on the server, not in a widget.

Frequently asked questions

Why does changing this setting open an upgrade dialog?+
The widget checks the edition from the client-side build information and, on anything other than Enterprise, opens the upgrade dialog instead of applying the change.
Why does the value reset to something else?+
The dialog's close callback writes a hardcoded literal into the input rather than restoring the previous selection. That value is the default for the Point of Sale setting the widget was written for.
Can I make the setting work on Community?+
Not through the view. The check is in the widget, and whatever actually gates the feature lives on the server.
Is there a boolean version?+
Yes, the upgrade boolean widget, which is the pattern this one mirrors for checkboxes.
Can I reuse it on another selection?+
Not safely, because the reset value is hardcoded for one specific setting. Copy the widget with your own value instead.

Knowing which Odoo edition your plan actually needs

Edition-gated features shape license cost and implementation scope, and the boundary is not always where people assume. We map requirements against Community and Enterprise before the contract, not after.

Book a free consultation

How this page was produced

The edition check, the dialog and the hardcoded reset value written in the close callback were read from upgrade_selection_field.js on the Odoo 19.0 branch, together with its source comment. Version coverage comes from the absence of the file on 16.0, a comparison with 17.0 and 18.0, and a byte comparison against the public development branch. Spotted an error? Tell us and we will correct the page.