Project

General

Profile

Bug #80400 » BackendUtility.php.patch

Viktor Leonhardt, 2017-03-22 16:38

View differences:

BackendUtility.php 2017-03-22 16:31:50.973017464 +0100
*/
public static function getItemLabel($table, $col, $printAllWrap = '')
{
// Check if column exists
if (is_array($GLOBALS['TCA'][$table]) && is_array($GLOBALS['TCA'][$table]['columns'][$col])) {
return $GLOBALS['TCA'][$table]['columns'][$col]['label'];
}
$cols = explode(',', $col);
$label = array();
foreach($cols as $c) {
// Check if column exists
if (is_array($GLOBALS['TCA'][$table]) && is_array($GLOBALS['TCA'][$table]['columns'][$c])) {
$label[] = $GLOBALS['TCA'][$table]['columns'][$c]['label'];
}
}
if(count($label) > 0) {
return $label;
}
if ($printAllWrap) {
GeneralUtility::deprecationLog('The third parameter of getItemLabel() is deprecated with TYPO3 CMS 6.2 and will be removed two versions later.');
$parts = explode('|', $printAllWrap);
(1-1/2)