From 4b67e78012d2fb6e6139818b35a440872990ec9b Mon Sep 17 00:00:00 2001 From: nathan Date: Mon, 4 Oct 2021 14:40:24 -0600 Subject: [PATCH] Fix selectbox grouped options were not using value if provided --- api/js/etemplate/et2_widget_selectbox.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/api/js/etemplate/et2_widget_selectbox.ts b/api/js/etemplate/et2_widget_selectbox.ts index d3e2b923c3..7addc5ea16 100644 --- a/api/js/etemplate/et2_widget_selectbox.ts +++ b/api/js/etemplate/et2_widget_selectbox.ts @@ -991,7 +991,8 @@ export class et2_selectbox extends et2_inputWidget if(sub == 'value') continue; if (typeof _options[key][sub] === 'object' && _options[key][sub] !== null) { - this._appendOptionElement(sub, + this._appendOptionElement( + typeof _options[key][sub]["value"] !== "undefined" ? _options[key][sub]["value"] : sub, _options[key][sub]["label"] ? _options[key][sub]["label"] : "", _options[key][sub]["title"] ? _options[key][sub]["title"] : "", group