Feature #61489

Add AbstractCondition to implement custom TypoScript Conditions

Added by Benni Mack about 5 years ago. Updated about 2 years ago.

Status:
Closed
Priority:
Should have
Assignee:
Category:
TypoScript
Target version:
Start date:
2014-09-09
Due date:
% Done:

100%

PHP Version:
Tags:
Complexity:
Sprint Focus:

Description

In order to streamline conditions and make
TypoScript conditions more flexible, an abstract class
AbstractCondition is introduced. Any class can extend
this abstract class, and TypoScript seamlessly calls
the class's main function that can completely flexibly
deal with the value that is set after the class.

possible conditions are:

[BigCompanyName\TypoScriptLovePackage\BennisTypoScriptCondition]

[BigCompanyName\TypoScriptLovePackage\BennisTypoScriptCondition = 7]

[BigCompanyName\TypoScriptLovePackage\BennisTypoScriptCondition = 7, != 6]

where the TypoScript Condition can deal with =/!= etc by itself.

Additionally, this change fixes one bug, where the
AbstractConditionMatcher would check on a condition name
and would not match, then there is an additional run.


Related issues

Related to TYPO3 Core - Feature #20450: Use t3lib_div::callUserFunction in typoscript userFunc condition Closed 2009-05-18

Associated revisions

Revision 071c4a16 (diff)
Added by Benni Mack about 5 years ago

[FEATURE] Add AbstractCondition for TS conditions

In order to streamline conditions and make
TypoScript conditions more flexible, an abstract class
AbstractCondition is introduced. Any class can extend
this abstract class, and TypoScript seamlessly calls
the class's main function that can completely flexibly
deal with the value that is set after the class.

possible conditions are:

[ACME\TypoScriptLovePackage\BennisCondition]

[ACME\TypoScriptLovePackage\BennisCondition = 7]

[ACME\TypoScriptLovePackage\BennisCondition = 7, != 6]

where the TypoScript Condition can deal with =/!= etc
by itself.

Additionally, this change fixes one bug, where the
AbstractConditionMatcher would check on a condition name
and would not match, then there is an additional
run through the subclass although not needed.

Releases: master
Resolves: #61489
Change-Id: I891edd367bb29b042cbbf6aa368cbf173dc3815d
Reviewed-on: http://review.typo3.org/32695
Reviewed-by: Christian Kuhn <>
Tested-by: Christian Kuhn <>
Reviewed-by: Wouter Wolters <>
Tested-by: Wouter Wolters <>

Revision 202e64c0 (diff)
Added by Stefan Neufeind almost 5 years ago

[FEATURE] Custom TypoScript-conditions also in backend

Make the feature for custom TypoScript-conditions available
in both frontend (was already there) and backend (new) by
moving it to the AbstractConditionMatcher.

Resolves: #63600
Related: #61489
Releases: master
Change-Id: I653f8cca53b23f6c16d81ed5ea3f2bc853e98a2e
Reviewed-on: http://review.typo3.org/35068
Reviewed-by: Wouter Wolters <>
Tested-by: Wouter Wolters <>
Reviewed-by: Benjamin Mack <>
Tested-by: Benjamin Mack <>

History

#1 Updated by Gerrit Code Review about 5 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/32695

#2 Updated by Gerrit Code Review about 5 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/32695

#3 Updated by Gerrit Code Review about 5 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/32695

#4 Updated by Gerrit Code Review about 5 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/32695

#5 Updated by Gerrit Code Review about 5 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/32695

#6 Updated by Gerrit Code Review about 5 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/32695

#7 Updated by Gerrit Code Review about 5 years ago

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

#8 Updated by Gerrit Code Review about 5 years ago

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

#9 Updated by Gerrit Code Review about 5 years ago

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

#10 Updated by Gerrit Code Review about 5 years ago

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

#11 Updated by Benni Mack about 5 years ago

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

#12 Updated by Riccardo De Contardi about 2 years ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF