Project

General

Profile

Actions

Feature #65920

closed

displayCond support to check if it contains a foreign_record(s)

Added by Andreas Allacher over 9 years ago. Updated almost 8 years ago.

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

0%

Estimated time:
PHP Version:
Tags:
Complexity:
Sprint Focus:
Remote Sprint

Description


Related issues 1 (0 open1 closed)

Has duplicate TYPO3 Core - Bug #65917: displayCond and ###REC_FIELD_ marker and certain relations not working correctly (e.g. sys_category)Closed2015-03-23

Actions
Actions #1

Updated by Gerrit Code Review over 9 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/38025

Actions #2

Updated by Mathias Schreiber over 9 years ago

  • Sprint Focus set to On Location Sprint
Actions #3

Updated by Anja Leichsenring over 9 years ago

  • Sprint Focus changed from On Location Sprint to Remote Sprint
Actions #4

Updated by Morton Jonuschat almost 9 years ago

  • Category set to FormEngine aka TCEforms
  • Status changed from Under Review to New

Original Patch has been abandoned

Actions #5

Updated by Franz Holzinger almost 9 years ago

This feature is missing in TYPO3 7.6.2.
The LOADED condition is not considered at all. The TYPO3 Backend (TCE) uses the foreign_table relation even if the demanded extension has not been installed.

field taxcat_id:
config foreign_table: static_tax_categories
displayCond EXT:static_info_tables_taxes:LOADED:true

This raises a TYPO3 exception.

Uncaught TYPO3 Exception
#1439569743: Field taxcat_id of table tt_products reference to foreign table static_tax_categories, but this table is not defined in TCA (More information)
UnexpectedValueException thrown in file /var/www/html/developer/typo3_src-7.6.2/typo3/sysext/backend/Classes/Form/FormDataProvider/AbstractItemProvider.php in line 895.
16 TYPO3\CMS\Backend\Form\FormDataProvider\AbstractItemProvider::buildForeignTableQuery(array, "taxcat_id") /var/www/html/developer/typo3_src-7.6.2/typo3/sysext/backend/Classes/Form/FormDataProvider/AbstractItemProvider.php:
00417:
00418: $foreignTable = $result['processedTca']['columns'][$fieldName]['config']['foreign_table'];
00419: $foreignTableQueryArray = $this->buildForeignTableQuery($result, $fieldName);
00420: $queryResource = $database->exec_SELECT_queryArray($foreignTableQueryArray);
00421:
15 TYPO3\CMS\Backend\Form\FormDataProvider\AbstractItemProvider::addItemsFromForeignTable(array, "taxcat_id", array) /var/www/html/developer/typo3_src-7.6.2/typo3/sysext/backend/Classes/Form/FormDataProvider/TcaSelectTreeItems.php:
00054: $staticItems = $fieldConfig['config']['items'];
00055:
00056: $fieldConfig['config']['items'] = $this->addItemsFromForeignTable($result, $fieldName, $fieldConfig['config']['items']);
00057: $dynamicItems = array_diff_key($fieldConfig['config']['items'], $staticItems);
00058:
Actions #6

Updated by Christian Kuhn almost 8 years ago

  • Status changed from New to Closed

Original patch has been abandoned, Andreas said it could be done differently. If that topic comes up again, it should be relatively easy to solve with the rewrite in https://review.typo3.org/#/c/50879/.

Franz: LOADED condition has been removed and it will stay that way.

Actions

Also available in: Atom PDF