Bug #70307
closedCategoryRegistry::addTcaColumn() ignores displayCond
100%
Description
I am adding a category field like this:
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::makeCategorizable( $_EXTKEY, 'pages', 'tx_wakapublicsolr_publication_facet_categories', array( 'label' => 'LLL:EXT:wakapublic_solr/Resources/Private/Language/locallang_db.xlf:pages.tx_wakapublicsolr_publication_facet_categories', 'exclude' => FALSE, 'displayCond' => 'FIELD:doktype:=:1', 'fieldConfiguration' => array( ... ), 'l10n_mode' => 'exclude', 'l10n_display' => 'hideDiff', 'position' => 'after:tx_wakapublicsolr_publication_download' ) );
The goal is to show this specific category field only on normal pages (doktype=1).
Internally, \TYPO3\CMS\Core\Category\CategoryRegistry::addTcaColumn($tableName, $fieldName, array $options) is called, which contains this assignment:
$columns = array( $fieldName => array( 'exclude' => $exclude, 'label' => $label, 'config' => static::getTcaFieldConfiguration($tableName, $fieldName, $fieldConfiguration), ), );
Here, $options['displayCond'] is dropped!
Therefore, all category fields can only be shown on all records, disregarding display conditions.
Files
Updated by Klaus Bitto about 9 years ago
- File forge-issue-70307.patch forge-issue-70307.patch added
Added patch.
Updated by Mathias Schreiber about 9 years ago
- Target version deleted (
next-patchlevel)
Updated by Gerrit Code Review almost 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 https://review.typo3.org/46057
Updated by Gerrit Code Review almost 9 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/46057
Updated by Gerrit Code Review almost 9 years ago
Patch set 1 for branch TYPO3_7-6 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/46380
Updated by Anonymous almost 9 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset ff8184e54c5637cf26eae9a5abddd2c9bf7d0113.
Updated by Gerrit Code Review almost 9 years ago
- Status changed from Resolved to Under Review
Patch set 1 for branch TYPO3_6-2 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/46381
Updated by Anonymous almost 9 years ago
- Status changed from Under Review to Resolved
Applied in changeset 66c8278fff4fdbf51114210035daf6ed504c7672.