[BUGFIX] Listview: Display parent field of categories 74/50274/3
authorMichael Oehlhof <typo3@oehlhof.de>
Wed, 19 Oct 2016 13:07:07 +0000 (15:07 +0200)
committerFrank Naegler <frank.naegler@typo3.org>
Mon, 7 Nov 2016 12:29:50 +0000 (13:29 +0100)
Resolves: #72311
Releases: master, 7.6
Change-Id: I47b19ccb5e74c5755630dba3626dad29b7b24fc7
Reviewed-on: https://review.typo3.org/50274
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Kurt Ludikovsky <kurt.ludikovsky@ludikovsky.at>
Tested-by: Kurt Ludikovsky <kurt.ludikovsky@ludikovsky.at>
Reviewed-by: Frank Naegler <frank.naegler@typo3.org>
Tested-by: Frank Naegler <frank.naegler@typo3.org>
typo3/sysext/backend/Classes/RecordList/AbstractRecordList.php
typo3/sysext/recordlist/Classes/RecordList/DatabaseRecordList.php

index 6446892..f2a75c4 100644 (file)
@@ -227,10 +227,10 @@ abstract class AbstractRecordList
         $colType = ($colType === 'th') ? 'th' : 'td';
         $noWrap = $this->no_noWrap ? '' : ' nowrap="nowrap"';
         // Start up:
-        $parent = isset($data['parent']) ? (int)$data['parent'] : 0;
+        $l10nParent = isset($data['_l10nparent_']) ? (int)$data['_l10nparent_'] : 0;
         $out = '
                <!-- Element, begin: -->
-               <tr ' . $rowParams . ' data-uid="' . (int)$data['uid'] . '" data-l10nparent="' . $parent . '">';
+               <tr ' . $rowParams . ' data-uid="' . (int)$data['uid'] . '" data-l10nparent="' . $l10nParent . '">';
         // Show icon and lines
         if ($this->showIcon) {
             $out .= '
index c568958..752441a 100644 (file)
@@ -1007,7 +1007,7 @@ class DatabaseRecordList extends AbstractDatabaseRecordList
             && isset($GLOBALS['TCA'][$table]['ctrl']['transOrigPointerField'])
             && !isset($GLOBALS['TCA'][$table]['ctrl']['transOrigPointerTable'])
         ) {
-            $theData['parent'] = $row[$GLOBALS['TCA'][$table]['ctrl']['transOrigPointerField']];
+            $theData['_l10nparent_'] = $row[$GLOBALS['TCA'][$table]['ctrl']['transOrigPointerField']];
         }
         $rowOutput .= $this->addElement(1, $theIcon, $theData, $row_bgColor);
         // Finally, return table row element: