Commit 71fc9567 authored by Carsten  Rose's avatar Carsten Rose
Browse files

#2542 / FormElement-Typ 'note' funktioniert nicht mit dynamic update

With API 'update-element' & 'content' also the 'input' column for FE.type='note' will be updated.
parent fe1c7664
......@@ -722,6 +722,9 @@ abstract class AbstractBuildForm {
if (isset($formElement[FE_NOTE])) {
$key = $formElement[FE_HTML_ID] . HTML_ID_EXTENSION_NOTE;
$json[API_ELEMENT_UPDATE][$key][API_ELEMENT_CONTENT] = $formElement[FE_NOTE];
$key = $formElement[FE_HTML_ID] . HTML_ID_EXTENSION_INPUT;
$json[API_ELEMENT_UPDATE][$key][API_ELEMENT_CONTENT] = $value;
}
// Show/ Hide the complete FormElement Row.
......@@ -2957,12 +2960,13 @@ abstract class AbstractBuildForm {
public function buildNote(array $formElement, $htmlFormElementName, $value, array &$json, $mode = FORM_LOAD) {
$json = $this->getFormElementForJson($htmlFormElementName, $value, $formElement);
//
return Support::wrapTag("<div class='" . CLASS_NOTE . "'>", $value);
$attribute = Support::doAttribute('id', $formElement[FE_HTML_ID] . HTML_ID_EXTENSION_INPUT);
return Support::wrapTag("<div $attribute class='" . CLASS_NOTE . "'>", $value);
}
/**
* Build Pill:
* Build Pill.
*
* @param array $formElement
* @param $htmlFormElementName
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment