From e092f84805d3d2e46c007a1b025146b70a9b84b9 Mon Sep 17 00:00:00 2001 From: Yuriy Bakhtin Date: Mon, 25 Sep 2023 16:06:42 +0200 Subject: [PATCH] Fix duplicate error and hint for RichText editor with defined form (#6598) --- CHANGELOG.md | 4 ++++ .../content/widgets/richtext/AbstractRichTextEditor.php | 1 + 2 files changed, 5 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 7cfcf21e30..d1f3f02d21 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,10 @@ HumHub Changelog ================ +1.14.5 (Unreleased) +--------------------------- +- Fix #6596: Fix duplicate error and hint for RichText editor with defined form + 1.14.4 (September 20, 2023) --------------------------- - Fix #6489: Never delete original file on store new version diff --git a/protected/humhub/modules/content/widgets/richtext/AbstractRichTextEditor.php b/protected/humhub/modules/content/widgets/richtext/AbstractRichTextEditor.php index f7b1eb8da4..c7c7bbf50a 100644 --- a/protected/humhub/modules/content/widgets/richtext/AbstractRichTextEditor.php +++ b/protected/humhub/modules/content/widgets/richtext/AbstractRichTextEditor.php @@ -181,6 +181,7 @@ class AbstractRichTextEditor extends JsInputWidget $inputOptions = $this->getInputAttributes(); if ($this->form != null) { + $this->fieldOptions['template'] = "{label}\n{input}"; $input = $this->form->field($this->model, $this->attribute, $this->fieldOptions)->textarea($inputOptions)->label(false); $richText = Html::tag('div', $this->editOutput($this->getValue()), $this->getOptions()); $richText = $this->getLabel() . $richText;