N°5428 - Request template: autocomplete field can not be a master field

This commit is contained in:
acognet
2022-08-19 15:06:38 +02:00
parent a92b1971c0
commit d33bd88832

View File

@@ -123,6 +123,20 @@ class ConsoleSelectObjectFieldRenderer extends FieldRenderer
{
$oOutput->AddCssFile($sFile);
}
$oOutput->AddJs(
<<<EOF
$("#{$this->oField->GetGlobalId()}").off("change").on("change", function(){
var me = this;
$(this).closest(".field_set").trigger("field_change", {
id: $(me).attr("id"),
name: $(me).closest(".form_field").attr("data-field-id"),
value: $(me).val()
})
.closest('.form_handler').trigger('value_change');
});
EOF
);
}
elseif($this->oField->GetControlType() == SelectObjectField::CONTROL_RADIO_VERTICAL)
{
@@ -226,9 +240,8 @@ EOF
JS
);
}
}
$oOutput->AddHtml((BlockRenderer::RenderBlockTemplates($oBlock)));
// JS Form field widget construct
$aValidators = array();