[!!!][TASK] Improve flex and TCA handling in FormEngine 79/50879/49
authorChristian Kuhn <lolli@schwarzbu.ch>
Sat, 3 Dec 2016 20:59:52 +0000 (21:59 +0100)
committerAnja Leichsenring <aleichsenring@ab-softlab.de>
Tue, 3 Jan 2017 13:33:10 +0000 (14:33 +0100)
commit38a1bc5dd7990b63e45c0419065cd02fe91187e9
treeb8709ea23ac0a2cde0658502d7b2b3cd8e3b0871
parent82cc3e9a0741d816000d55cd606a9a9ce87a1a1b
[!!!][TASK] Improve flex and TCA handling in FormEngine

The patch adapts a series of nasty form engine areas to more solid
code. The evaluate condition code is rewritten and works much better
in flex form scenarios. The suggest wizard and svg tree are much
more solid in flex forms. The group element is rewritten
towards a better readable and easier to refactor code, dropping
method dbFileIcons(). A bunch of issues is resolved along the way.

* TCA "default" now works in flex form section container elements
* The "displayCond" parser is now strict and throws exceptions on
  invalid syntax and wrong referenced fields to help debugging
  faulty display conditions
* TCA displayCond on flex fields can now be prefixed with the
  sheet name and can reference field values from neighbor sheets
* TCA displayCond now works with flex section containers
* TCA flex section container now throw an exception if select or
  group fields configure a MM relation - this is not supported
* TCA ctrl requestUpdate field is dropped, onChange=reload is now allowed
  not only on flex form fields, but also on normal columns fields
* TCA tree now works as section container element and initializes
  correctly on new records and new containers
* GroupElement rewrite to drop dbFileIcons()
* config option maxitems now optional for type=group and type=select
  and defaults to "many items allowed"
* inline now works in "fancy" flex situations with "new" records
  by handing the final dataStructureIdentifier around
* FormEngine no longer loads extJS

Change-Id: Id1d081627529cc1502bb198389e5bd69372815cd
Resolves: #78899
Resolves: #72307
Resolves: #75646
Resolves: #76637
Resolves: #72106
Resolves: #78824
Resolves: #76793
Resolves: #68247
Resolves: #69715
Related: #78460
Related: #67198
Related: #72294
Releases: master
Reviewed-on: https://review.typo3.org/50879
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Benni Mack <benni@typo3.org>
Tested-by: Benni Mack <benni@typo3.org>
Reviewed-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
Tested-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
91 files changed:
typo3/sysext/backend/Classes/Controller/FormFlexAjaxController.php [new file with mode: 0644]
typo3/sysext/backend/Classes/Controller/FormInlineAjaxController.php
typo3/sysext/backend/Classes/Controller/FormSelectTreeAjaxController.php [new file with mode: 0644]
typo3/sysext/backend/Classes/Controller/SelectTreeController.php [deleted file]
typo3/sysext/backend/Classes/Controller/Wizard/SuggestWizardController.php
typo3/sysext/backend/Classes/Form/AbstractNode.php
typo3/sysext/backend/Classes/Form/Container/FlexFormContainerContainer.php
typo3/sysext/backend/Classes/Form/Container/FlexFormElementContainer.php
typo3/sysext/backend/Classes/Form/Container/FlexFormEntryContainer.php
typo3/sysext/backend/Classes/Form/Container/FlexFormNoTabsContainer.php
typo3/sysext/backend/Classes/Form/Container/FlexFormSectionContainer.php
typo3/sysext/backend/Classes/Form/Container/FlexFormTabsContainer.php
typo3/sysext/backend/Classes/Form/Container/InlineControlContainer.php
typo3/sysext/backend/Classes/Form/Container/InlineRecordContainer.php
typo3/sysext/backend/Classes/Form/Container/SingleFieldContainer.php
typo3/sysext/backend/Classes/Form/DatabaseFileIconsHookInterface.php
typo3/sysext/backend/Classes/Form/Element/AbstractFormElement.php
typo3/sysext/backend/Classes/Form/Element/GroupElement.php
typo3/sysext/backend/Classes/Form/Element/ImageManipulationElement.php
typo3/sysext/backend/Classes/Form/Element/InputColorPickerElement.php
typo3/sysext/backend/Classes/Form/Element/InputTextElement.php
typo3/sysext/backend/Classes/Form/Element/SelectCheckBoxElement.php
typo3/sysext/backend/Classes/Form/Element/SelectMultipleSideBySideElement.php
typo3/sysext/backend/Classes/Form/Element/SelectSingleBoxElement.php
typo3/sysext/backend/Classes/Form/Element/SelectSingleElement.php
typo3/sysext/backend/Classes/Form/Element/SelectTreeElement.php
typo3/sysext/backend/Classes/Form/FormDataCompiler.php
typo3/sysext/backend/Classes/Form/FormDataProvider/AbstractItemProvider.php
typo3/sysext/backend/Classes/Form/FormDataProvider/DatabaseRecordTypeValue.php
typo3/sysext/backend/Classes/Form/FormDataProvider/DatabaseRowDefaultValues.php
typo3/sysext/backend/Classes/Form/FormDataProvider/DatabaseUniqueUidNewRow.php
typo3/sysext/backend/Classes/Form/FormDataProvider/EvaluateDisplayConditions.php
typo3/sysext/backend/Classes/Form/FormDataProvider/TcaFlexProcess.php
typo3/sysext/backend/Classes/Form/FormDataProvider/TcaGroup.php
typo3/sysext/backend/Classes/Form/FormDataProvider/TcaInline.php
typo3/sysext/backend/Classes/Form/FormDataProvider/TcaInlineConfiguration.php
typo3/sysext/backend/Classes/Form/FormDataProvider/TcaInputPlaceholders.php
typo3/sysext/backend/Classes/Form/FormDataProvider/TcaRecordTitle.php
typo3/sysext/backend/Classes/Form/FormDataProvider/TcaSelectItems.php
typo3/sysext/backend/Classes/Form/FormDataProvider/TcaSelectTreeItems.php
typo3/sysext/backend/Classes/Form/FormResultCompiler.php
typo3/sysext/backend/Classes/Form/Wizard/SuggestWizard.php
typo3/sysext/backend/Configuration/Backend/AjaxRoutes.php
typo3/sysext/backend/Resources/Private/Templates/Wizards/SuggestWizard.html
typo3/sysext/backend/Resources/Public/JavaScript/FormEngine/Element/SelectTreeElement.js
typo3/sysext/backend/Resources/Public/JavaScript/FormEngine/Element/SvgTree.js
typo3/sysext/backend/Resources/Public/JavaScript/FormEngineFlexForm.js
typo3/sysext/backend/Resources/Public/JavaScript/FormEngineSuggest.js
typo3/sysext/backend/Tests/Unit/Controller/FormSelectTreeAjaxControllerTest.php [new file with mode: 0644]
typo3/sysext/backend/Tests/Unit/Controller/SelectTreeControllerTest.php [deleted file]
typo3/sysext/backend/Tests/Unit/Controller/Wizard/SuggestWizardControllerTest.php
typo3/sysext/backend/Tests/Unit/Form/Element/GroupElementTest.php [deleted file]
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/DatabaseRecordTypeValueTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/DatabaseUniqueUidNewRowTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/EvaluateDisplayConditionsTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/TcaFlexProcessTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/TcaGroupTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/TcaInlineConfigurationTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/TcaInlineTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/TcaInputPlaceholdersTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/TcaRecordTitleTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/TcaSelectItemsTest.php
typo3/sysext/backend/Tests/Unit/Form/NodeFactoryTest.php
typo3/sysext/backend/Tests/Unit/Form/Wizard/SuggestWizardTest.php
typo3/sysext/core/Classes/DataHandling/DataHandler.php
typo3/sysext/core/Classes/Database/RelationHandler.php
typo3/sysext/core/Classes/Migrations/TcaMigration.php
typo3/sysext/core/Classes/Resource/Service/UserFileInlineLabelService.php
typo3/sysext/core/Configuration/TCA/be_groups.php
typo3/sysext/core/Configuration/TCA/be_users.php
typo3/sysext/core/Configuration/TCA/pages.php
typo3/sysext/core/Configuration/TCA/sys_file_collection.php
typo3/sysext/core/Configuration/TCA/sys_file_storage.php
typo3/sysext/core/Configuration/TCA/sys_filemounts.php
typo3/sysext/core/Documentation/Changelog/master/Breaking-78899-DroppedFormEngineMethods.rst [new file with mode: 0644]
typo3/sysext/core/Documentation/Changelog/master/Breaking-78899-RemovedExtJsCodeFromFormEngineResultArray.rst [new file with mode: 0644]
typo3/sysext/core/Documentation/Changelog/master/Deprecation-78899-FormEngineMethods.rst [new file with mode: 0644]
typo3/sysext/core/Documentation/Changelog/master/Deprecation-78899-TCACtrlFieldRequestUpdateDropped.rst [new file with mode: 0644]
typo3/sysext/core/Documentation/Changelog/master/Feature-78899-TCAMaxitemsOptional.rst [new file with mode: 0644]
typo3/sysext/core/Documentation/Changelog/master/Important-78899-DisplayCondStrictParsing.rst [new file with mode: 0644]
typo3/sysext/core/Tests/Unit/Migrations/TcaMigrationTest.php
typo3/sysext/extbase/Classes/Persistence/Generic/Mapper/DataMapFactory.php
typo3/sysext/extbase/Tests/Functional/Fixtures/Extensions/blog_example/Configuration/TCA/tx_blogexample_domain_model_blog.php
typo3/sysext/extbase/Tests/Functional/Fixtures/Extensions/blog_example/Configuration/TCA/tx_blogexample_domain_model_person.php
typo3/sysext/extbase/Tests/Functional/Fixtures/Extensions/blog_example/Configuration/TCA/tx_blogexample_domain_model_post.php
typo3/sysext/extbase/Tests/Functional/Fixtures/Extensions/blog_example/Configuration/TCA/tx_blogexample_domain_model_tag.php
typo3/sysext/frontend/Configuration/TCA/tt_content.php
typo3/sysext/lang/Resources/Private/Language/locallang_csh_corebe.xlf
typo3/sysext/rsaauth/Classes/Form/Element/RsaInputElement.php
typo3/sysext/sys_action/Configuration/TCA/sys_action.php
typo3/sysext/workspaces/Configuration/TCA/sys_workspace.php