Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[!!!][BUGFIX] Fix wrong error path of validation
Add the form name as top level property to the validation results to let the form field viewhelper attribute "errorClass" work. Releases: master, 8.7 Resolves: #82093 Change-Id: I2d1c0845c5ab15d68393d5b491bf26db8f3f17c0 Reviewed-on: https://review.typo3.org/54150 Reviewed-by: Mathias Schreiber <mathias.schreiber@typo3.com> Tested-by: Mathias Schreiber <mathias.schreiber@typo3.com> Tested-by: TYPO3com <no-reply@typo3.com> Reviewed-by: Benjamin Kott <benjamin.kott@outlook.com> Tested-by: Benjamin Kott <benjamin.kott@outlook.com>
- Loading branch information
1 parent
851d7ef
commit b3190c3
Showing
4 changed files
with
116 additions
and
2 deletions.
There are no files selected for viewing
57 changes: 57 additions & 0 deletions
57
...ore/Documentation/Changelog/8.7.x/Breaking-82093-ExtFormFieldPartialChanged.rst
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
.. include:: ../../Includes.txt | ||
|
||
================================================================= | ||
Breaking: #82093 - EXT:form Partials/Field/Field.html has changed | ||
================================================================= | ||
|
||
See :issue:`82093` | ||
|
||
Description | ||
=========== | ||
|
||
To let the form field viewhelper attribute errorClass work, the partial | ||
"EXT:form/Resources/Private/Frontend/Partials/Field/Field.html" has been changed. | ||
|
||
.. code-block:: html | ||
|
||
<f:form.validationResults for="{element.identifier}"> | ||
|
||
has been changed to | ||
|
||
.. code-block:: html | ||
|
||
<f:form.validationResults for="{element.rootForm.identifier}.{element.identifier}"> | ||
|
||
|
||
Impact | ||
====== | ||
|
||
Users who overwrite this partial by its own partial have to make adjustments. | ||
Otherwise no "has-error" class will be rendered in case of form validation errors | ||
into the parents <div class="form-group"> and the <span class="help-block"> | ||
content will not be rendered. | ||
|
||
|
||
Affected Installations | ||
====================== | ||
|
||
All installations with overwritten partial "EXT:form/Resources/Private/Frontend/Partials/Field/Field.html" | ||
|
||
|
||
Migration | ||
========= | ||
|
||
Change the partial Field/Field.html within your site package. | ||
|
||
.. code-block:: html | ||
|
||
<f:form.validationResults for="{element.identifier}"> | ||
|
||
change to | ||
|
||
.. code-block:: html | ||
|
||
<f:form.validationResults for="{element.rootForm.identifier}.{element.identifier}"> | ||
|
||
|
||
.. index:: Frontend, ext:form, NotScanned |
57 changes: 57 additions & 0 deletions
57
...re/Documentation/Changelog/master/Breaking-82093-ExtFormFieldPartialChanged.rst
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
.. include:: ../../Includes.txt | ||
|
||
================================================================= | ||
Breaking: #82093 - EXT:form Partials/Field/Field.html has changed | ||
================================================================= | ||
|
||
See :issue:`82093` | ||
|
||
Description | ||
=========== | ||
|
||
To let the form field viewhelper attribute errorClass work, the partial | ||
"EXT:form/Resources/Private/Frontend/Partials/Field/Field.html" has been changed. | ||
|
||
.. code-block:: html | ||
|
||
<f:form.validationResults for="{element.identifier}"> | ||
|
||
has been changed to | ||
|
||
.. code-block:: html | ||
|
||
<f:form.validationResults for="{element.rootForm.identifier}.{element.identifier}"> | ||
|
||
|
||
Impact | ||
====== | ||
|
||
Users who overwrite this partial by its own partial have to make adjustments. | ||
Otherwise no "has-error" class will be rendered in case of form validation errors | ||
into the parents <div class="form-group"> and the <span class="help-block"> | ||
content will not be rendered. | ||
|
||
|
||
Affected Installations | ||
====================== | ||
|
||
All installations with overwritten partial "EXT:form/Resources/Private/Frontend/Partials/Field/Field.html" | ||
|
||
|
||
Migration | ||
========= | ||
|
||
Change the partial Field/Field.html within your site package. | ||
|
||
.. code-block:: html | ||
|
||
<f:form.validationResults for="{element.identifier}"> | ||
|
||
change to | ||
|
||
.. code-block:: html | ||
|
||
<f:form.validationResults for="{element.rootForm.identifier}.{element.identifier}"> | ||
|
||
|
||
.. index:: Frontend, ext:form, NotScanned |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
typo3/sysext/form/Resources/Private/Frontend/Partials/Field/Field.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters