#55976Override TCA config with TSconfig - TCEFORM
Description
Some of the TCA config can not be overridden with TSconfig, e.g.:
TCEFORM.tt_content.imagewidth.config.range.upper = 1600
will NOT work atm.
Reviews 0
No change resolves or names this issue in its commit message, and no comment links one.
Related issues 2
Files 1
History 17
-
Markus Klein commented 02/14/14, 13:17
-
Jan Kiesewetter commented 02/14/14, 15:36
As config.range is not in the key list:
http://docs.typo3.org/typo3cms/TSconfigReference/PageTsconfig/TCEform/Index.htmlIt’s a feature.
I selected Tracker: Feature -
Felix Kopp changed status
NewNeeds Feedback 12/13/14, 14:59 -
Alexander Opitz changed category status
Needs FeedbackNew 06/15/15, 10:19 -
Susanne Moog changed Sprint Focus PRC 08/07/15, 10:53
-
Luc Muller commented 09/29/16, 15:54
Hi All
I would like to put a +1 on this bug.
Having the problem in powermail, to make a field optional
TCEFORM.tx_powermail_domain_model_page.title.config.size = 100 <= works
TCEFORM.tx_powermail_domain_model_page.title.config.eval = trim <= do not work
TCEFORM.tx_powermail_domain_model_page.title.config.eval := removeFromList(required) <= do not work:’(
-
Michael Christian commented and changed tracker
FeatureBug subjectOverride TCA config with TSconfigOverride TCA config with TSconfig - TCEFORM priorityShould haveMust have TYPO3 Version 7 Is Regression 0 12/23/16, 16:42I have the same bug with typo3 V7.6.14
The doc says this should be work – Look at: “[table name].[field].config.[key]“
https://docs.typo3.org/typo3cms/TSconfigReference/7.6/PageTsconfig/TCEform/TCEFORM.tt_content.header.config.max = 20 <= works
TCEFORM.tt_content.rowDescription.config.rows = 10 <= works
TCEFORM.tt_content.rowDescription.config.eval = required <= do not work
TCEFORM.tt_content.header_link.config.max = 10 <= works
TCEFORM.tt_content.header_link.config.wizards.link.title = Hello :-) World! <= do not work
TCEFORM.tt_content.header_link.config.wizards.link.JSopenParams = width=200,height=200,status=0,menubar=0,scrollbars=1 <= do not workCould someone fix this bug pleeeeeease!
-
Andreas Dörler commented 02/28/17, 14:57
Hi,
I can confirm, that overriding eval does not work.
My usecase ist tx_news:- There is one sysfolder where only news of type internal url is allowed.
- The url should be optional, therefore I’ve set the following Page TS config in this sysfolder:
TCEFORM.tx_news_domain_model_news.internalurl.config.eval = trim
The workaround in comment 7 of #14669 could work, but it would be more comfortable to use Page TS config.
Kind regards
Andreas -
Georg Ringer changed Related to #80265 01/02/18, 19:24
-
Riccardo De Contardi commented and changed tracker
BugFeature 07/21/18, 21:59AFAIK the properties that can be overridden are listed here: https://docs.typo3.org/typo3cms/TSconfigReference/PageTsconfig/TceForm.html#config
I change this to a feature request. Thank you.
-
Tilo Baller changed Related to #14669 11/08/18, 10:59
-
Tilo Baller commented 11/08/18, 12:00
As there doesn’t seem to be any possibility to manipulate the allowOverrideMatrix after the getMainFieldsClass hook was removed with breaking change #63846 (https://docs.typo3.org/typo3cms/extensions/core/Changelog/7.5/Breaking-69568-FormEngine.html), even not in current master (as of 18-11-08), we currently use Reflection as a workaround.
E.g. to allow overriding ‘eval’-config on an input tca field with
TCEFORM.pages.lastUpdated.config.eval = requiredthe following code placed in an extensions ext_localconf.php does the job for us:$reflectionClassFormEngineUtility = new ReflectionClass(\TYPO3\CMS\Backend\Form\Utility\FormEngineUtility::class); $reflectionPropertyAllowOverrideMatrix = $reflectionClassFormEngineUtility->getProperty('allowOverrideMatrix'); $reflectionPropertyAllowOverrideMatrix->setAccessible(true); // make protected property accessible $allowOverrideMatrix = $reflectionPropertyAllowOverrideMatrix->getValue(); $allowOverrideMatrix['input'][] = 'eval'; $reflectionPropertyAllowOverrideMatrix->setValue($allowOverrideMatrix);See also the
$allowOverrideMatrixproperty intypo3/sysext/backend/Classes/Form/Utility/FormEngineUtility.phpto see which array key is necessary to manipulate depending on your field type.Tested with TYPO3 7.6.31 and PHP 5.6.
-
Benni Mack changed Sprint Focus
PRCNeeds Decision 03/24/20, 17:52 -
Mathias Bolt Lesniak commented 06/18/20, 09:45
+1 from me on this. Would be very useful and increase flexibility. It would make it possible to make a filed required dependent on where in the page tree and which user is editing. I have a use case for that. O:-)
-
Christoph Kratz commented and changed attached Bildschirmfoto 2021-11-10 um 22.51.36.png 11/10/21, 21:52
Works also in TYPO3 v11 with PHP 7.4. The function is especially important when you need different settings depending on the page type or location.
+1!
-
Sybille Peters commented 05/16/24, 10:26
The link above to the list of things which can be overriden is broken.
You can find information in the TSconfig docs for TCEFORM config or in the source code FormEngineUtility::$formEngineUtility
-
Georg Ringer commented and changed status
NewClosed 08/03/24, 07:07hey!
currently we don’t plan to allow more fields. you can use a custom formdataprovider or e.g. https://github.com/b13/pagetsconfig to achieve what you need.
therefore closing the issue
Is this a feature or a bug. Should it be working like this? What do the docs say?