[BUGFIX] Removing an element from select field must trigger validation 01/40701/3
authorFrank Nägler <typo3@naegler.net>
Sat, 27 Jun 2015 20:46:00 +0000 (22:46 +0200)
committerAnja Leichsenring <aleichsenring@ab-softlab.de>
Mon, 29 Jun 2015 07:54:11 +0000 (09:54 +0200)
This patch ensures that re-validation is triggered in case
an element is removed from a select field.

Resolves: #67791
Releases: master
Change-Id: I8b2b6e67216ba9410a3a404fe697064748cd5871
Reviewed-on: http://review.typo3.org/40701
Reviewed-by: Markus Klein <markus.klein@typo3.org>
Reviewed-by: Christian Kuhn <lolli@schwarzbu.ch>
Tested-by: Christian Kuhn <lolli@schwarzbu.ch>
Reviewed-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
Tested-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
typo3/sysext/backend/Resources/Public/JavaScript/FormEngine.js

index 5f5dafd..a2412f0 100644 (file)
@@ -553,6 +553,9 @@ define('TYPO3/CMS/Backend/FormEngine', ['jquery'], function ($) {
                                // make sure to update the hidden field value when modifying the select value
                                FormEngine.updateHiddenFieldValueFromSelect($listFieldEl, FormEngine.getFieldElement(fieldName));
                                FormEngine.legacyFieldChangedCb();
+                               if (typeof FormEngine.Validation !== 'undefinied' && typeof FormEngine.Validation.validate === 'function') {
+                                       FormEngine.Validation.validate();
+                               }
                        }
                });