Project

General

Profile

Actions

Bug #60399

closed

rte_transform "db" is not applied to RTE-fields defined via "foreign_types" / palettes

Added by Robert Heinig over 9 years ago. Updated over 5 years ago.

Status:
Closed
Priority:
Must have
Assignee:
-
Category:
-
Target version:
-
Start date:
2014-07-19
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
6.2
PHP Version:
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

Scenario:
I needed an RTE-field for sys_file_reference, so i created one the usual way (defaultExtras, softref ...).
Then i created a custom palette for sys_file_reference and added the fields i needed to it. This palette is used via ExtensionManagementUtility::getFileFieldTCAConfig() and "foreign_types" in a tt_content FAL-relation field.

Problem:
Visually there are no problems while editing the FAL elements within the tt_content elements. The text added to the RTE field is visible in frontend, but the rte_transform stuff with direction "db" was never applied to the RTE field before saving the data to DB - which leads e.g. to the very messy problem, that all links created with the link wizard will be stored as "a" elements with absolute URLs and not as internal "link" elements.

Way to a solution:
To hotfix this i found out that BackendUtility::getTCAtypes() used in
DataHandler->fillInFieldArray() does not return useful field information. It returns the showitem definition of the original "types" array of the sys_file_reference TCA, which contains no fields at all.
My hotfix just checks "$incomingFieldArrayKeys" in DataHandler->fillInFieldArray() for "_TRANSFORM_"-fields and adds the required field definition to "$types_fieldConfig" if it´s missing there.
For a cleaner solution the "foreign_types" have to be considered and there fields extracted - but i was not able to spot logic that does s.th. like this.


Files

backendutility.patch (1013 Bytes) backendutility.patch Patch for TYPO3 6.2 LTS Anonymous, 2016-05-24 18:30

Related issues 2 (0 open2 closed)

Related to TYPO3 Core - Bug #70837: TCA rte configuration in palettesClosed2015-10-19

Actions
Related to TYPO3 Core - Bug #76745: TCA: defaultExtras configuration is ignored when RTE is placed inside a paletteClosedChristian Kuhn2016-06-23

Actions
Actions

Also available in: Atom PDF