Issue Bug Closed

#55166label_alt does not work with itemsProcFunc

Christian Weiske 01/20/14, 14:25 updated 02/28/14, 11:01

Description

Using label_alt + label_alt_force to show values from a column that uses an “itemsProcFunc” does not work with TYPO3 4.7, 6.1 and 6.2. It works fine in 4.6.

Scenario:
  • Table with two columns, “first” and “second”.
    • ctrl array:
      • 'label' => 'first',
      • 'label_alt' => 'second',
      • 'label_alt_force' => 1,
  • second column is of type => select
    • 'items' => array(array('default' => 'default'))
    • 'itemsProcFunc' => 'somefunc.php'

The itemsProcFunc adds additional key-value pairs to the items array.

Now the backend list view only shows a label of “@foo, default@” (this item is in items from the beginning), but not “@foo, bar@” if “bar” is added via the itemsProcFunc. It only shows “@foo, @”.

Reasons for this seems to be typo3/sysext/backend/Classes/Utility/BackendUtility.php:getProcessedValue() which does not use itemsProcFunc for select types.

Attached is an extension “test_label”, which demonstrates the problem.
Just install it and create two records, one “default / default” one, and one “foo / foo” one. The “default, default” title is shown, the “foo, foo” one only as “foo, “.

Reviews 0

No change resolves or names this issue in its commit message, and no comment links one.