Bug #70052

Story #69617: FormEngine bugs

TCA displayCond not evaluated

Added by Georg Ringer about 4 years ago. Updated almost 2 years ago.

Status:
Closed
Priority:
Must have
Assignee:
-
Category:
FormEngine aka TCEforms
Target version:
Start date:
2015-09-23
Due date:
% Done:

100%

TYPO3 Version:
7
PHP Version:
Tags:
Complexity:
Is Regression:
No
Sprint Focus:
Remote Sprint

Description

If EXT:static_info_tables is not installed, and a record "tx_rtehtmlarea_acronym" is created, an exception is thrown:

Uncaught TYPO3 Exception
#1439569743: Field static_lang_isocode of table tx_rtehtmlarea_acronym reference to foreign table static_languages, but this table is not defined in TCA

TCA of this field has:

'displayCond' => 'EXT:static_info_tables:LOADED:true',


Related issues

Related to TYPO3 Core - Task #70561: Adapt tx_rtehtmlarea_acronym TCA to TYPO3 CMS 7 FormEngine Closed 2015-10-10
Related to TYPO3 Core - Task #70545: tx_rtehtmlarea_acronym - kick dependency to static_info_tables, deprecate isLoaded display condition Closed 2015-10-09
Related to Static Info Tables - Bug #71005: Add tx_rtehtmlarea_acronym sys_language_uid TCA field Resolved 2015-10-25
Related to TYPO3 Core - Bug #76958: displayCond LOADED does not check the loaded extension Closed 2016-07-06
Related to TYPO3 Core - Bug #78853: BE doesn't execute displayCond of extension flexform Rejected 2016-12-01
Duplicated by TYPO3 Core - Bug #70051: TCA displayCond not evaluated Closed 2015-09-23

Associated revisions

Revision 81cc14db (diff)
Added by Christian Kuhn almost 4 years ago

[BUGFIX] TCA displayCond with EXT:anExt:LOADED fails

Due to the new condition evaluation construct in FormEngine, the
EXT:anExtension:LOADED display condition is very unfortunate since
the evaluation happens at the end, and depending on the configuration
of affected field, the former data provider may fail fetching data.

This is solved by deprecating this condition since it works contrary
to the "additive" TCA system: Extensions should always add or change
other extensions TCA, but should not have a "negative" dependency
to each other like "Don't do if that extension is loaded".

Core is affected at two places in combination with
static_info_tables. This also lowers the dependency from core
to static_info_tables again, which is not a good thing in
first place.

A patch for static_info_tables adding the fields there is pending.

Resolves: #70052
Releases: master
Change-Id: Iccb7a116d1f89e55e80e389a2448759eca326605
Reviewed-on: https://review.typo3.org/44251
Reviewed-by: Morton Jonuschat <>
Tested-by: Morton Jonuschat <>
Reviewed-by: Jan Helke <>
Tested-by: Jan Helke <>
Reviewed-by: Christian Kuhn <>
Tested-by: Christian Kuhn <>

History

#1 Updated by Markus Klein about 4 years ago

  • Description updated (diff)
  • Target version set to 7 LTS
  • Sprint Focus set to Remote Sprint

#2 Updated by Georg Ringer about 4 years ago

some further description:

the displaycond is

'displayCond' => 'EXT:static_info_tables:LOADED:true',

so the issue is only reproducable if static_info_tables is not installed.

the exception is thrown from TYPO3\CMS\Backend\Form\FormDataProvider\TcaSelectItems because the displayconds are evaluated too late as EvaluateDisplayConditions is called afterwards

#3 Updated by Christian Kuhn about 4 years ago

will think about something with morton.

#4 Updated by Benni Mack about 4 years ago

  • Category set to FormEngine aka TCEforms

#5 Updated by Gerrit Code Review almost 4 years ago

  • Status changed from Accepted 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 https://review.typo3.org/44251

#6 Updated by Gerrit Code Review almost 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 https://review.typo3.org/44251

#7 Updated by Gerrit Code Review almost 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 https://review.typo3.org/44251

#8 Updated by Gerrit Code Review almost 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 https://review.typo3.org/44251

#9 Updated by Christian Kuhn almost 4 years ago

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

#10 Updated by Bernhard Berger over 3 years ago

I need to clearify in a comment here:

the issue of a non working displayCond has not be resolved here. What got resolved was an exception caused by static_info_tables and tx_htmlarea. I've seen now on 2 seperated occasions that extension developers re-added their EXT:-condition because they saw this issue marked as 'resolved'.

Additionally displayCond using EXT: has been now marked as deprecated - and not been fixed!

#11 Updated by Riccardo De Contardi almost 2 years ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF