Project

General

Profile

Actions

Bug #70307

closed

CategoryRegistry::addTcaColumn() ignores displayCond

Added by Klaus Bitto about 9 years ago. Updated about 6 years ago.

Status:
Closed
Priority:
Must have
Assignee:
-
Category:
Backend API
Target version:
-
Start date:
2015-10-02
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
6.2
PHP Version:
5.5
Tags:
Complexity:
no-brainer
Is Regression:
No
Sprint Focus:

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

forge-issue-70307.patch (752 Bytes) forge-issue-70307.patch Klaus Bitto, 2015-10-02 14:45
Actions #2

Updated by Mathias Schreiber about 9 years ago

  • Target version deleted (next-patchlevel)
Actions #3

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

Actions #4

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

Actions #5

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

Actions #6

Updated by Anonymous almost 9 years ago

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

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

Actions #8

Updated by Anonymous almost 9 years ago

  • Status changed from Under Review to Resolved
Actions #9

Updated by Benni Mack about 6 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF