Feature #66907

Add possibility to the FLUIDTEMPLATE Content Object to do data processing before rendering

Added by Patrick Broens about 4 years ago. Updated 10 months ago.

Status:
Closed
Priority:
Should have
Category:
Frontend
Target version:
-
Start date:
2015-05-12
Due date:
% Done:

100%

PHP Version:
Tags:
Complexity:
easy
Sprint Focus:

Description

Sometimes it is needed or can be very helpful to do processing on the $data variable of a content element. Some content elements, provided by the core, are using constructs which Fluid can not handle out of the box, like tt_content.table. The contents of the table is entered in the field 'bodytext' as a CSV string. It would be great when this string is transformed into an array before sending it to the view. Using a viewhelper for this is architectural not a good solution.

We should introduce a way to connect your own data processors to the content object using TypoScript, like

my_custom_ctype = FLUIDTEMPLATE
my_custom_ctype {
    templateName = CustomName
    settings {
        extraParam = 1
    }
    dataProcessing {
        1 = TYPO3/CMS/Frontend/DataProcessing/MyFirstCustomProcessor
        2 = TYPO3/CMS/Frontend/DataProcessing/MySecondCustomProcessor
        2 {
            options {
                myOption = SomeValue
            }
        }
    }
}

This way the data processing is extendible and can be called by multiple extensions if necessary. Using TypoScript instead of a hook makes it more flexible and better understandable for integrators.


Related issues

Related to TYPO3 Core - Feature #67658: Introduce DataProcessors for FLUIDTEMPLATE Closed 2015-06-21
Related to TYPO3 Core - Feature #67890: Redesign FluidTemplateDataProcessorInterface Closed 2015-07-02

Associated revisions

Revision 46fd9abd (diff)
Added by Patrick Broens about 4 years ago

[FEATURE] Add Data Processing to FLUIDTEMPLATE content object

The content object FLUIDTEMPLATE is extended with `dataProcessing`. With this
setting you can add full namespace class references, which can manipulate
the $data variable of the current rendered content object, like tt_content or
page, before assigning this variable to the view.

Change-Id: I757db37d86e1cf907de0116c3c63effc5270a3c1
Resolves: #66907
Releases: master
Reviewed-on: http://review.typo3.org/39519
Reviewed-by: Andreas Fernandez <>
Reviewed-by: Wouter Wolters <>
Reviewed-by: Frans Saris <>
Tested-by: Frans Saris <>
Reviewed-by: Benjamin Mack <>
Tested-by: Benjamin Mack <>

History

#1 Updated by Patrick Broens about 4 years ago

  • Description updated (diff)

#2 Updated by Patrick Broens about 4 years ago

  • Description updated (diff)

#3 Updated by Patrick Broens about 4 years ago

  • Description updated (diff)

#4 Updated by Gerrit Code Review about 4 years ago

  • Status changed from New to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/39519

#5 Updated by Gerrit Code Review about 4 years ago

Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/39519

#6 Updated by Gerrit Code Review about 4 years ago

Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/39519

#7 Updated by Gerrit Code Review about 4 years ago

Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/39519

#8 Updated by Gerrit Code Review about 4 years ago

Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/39519

#9 Updated by Gerrit Code Review about 4 years ago

Patch set 6 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/39519

#10 Updated by Patrick Broens about 4 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100

#11 Updated by Benni Mack 10 months ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF