[BUGFIX] Change default label for sys_file_references 77/40477/7
authorBernd Wilke <t3A@pi-phi.de>
Fri, 5 Jun 2015 07:38:43 +0000 (09:38 +0200)
committerAlexander Opitz <opitz.alexander@googlemail.com>
Thu, 29 Oct 2015 11:02:07 +0000 (12:02 +0100)
In the List module you can select additional fields to be displayed.
For fields referencing files only, the uid is shown which does give
no hint to the real referenced file.
This change selects the uid_local field, which selects the filename
from sys_file for display.

Resolves: #67303
Releases: master, 6.2
Change-Id: I8dd301ff8d8d17baa67fafd26892a3eeea46509b
Reviewed-on: https://review.typo3.org/40477
Reviewed-by: Oliver Hader <oliver.hader@typo3.org>
Tested-by: Oliver Hader <oliver.hader@typo3.org>
Reviewed-by: Alexander Opitz <opitz.alexander@googlemail.com>
Tested-by: Alexander Opitz <opitz.alexander@googlemail.com>
typo3/sysext/core/Configuration/TCA/sys_file_reference.php
typo3/sysext/impexp/Tests/Functional/Fixtures/ImportExportXml/pages-and-ttcontent-with-image-but-not-included.xml
typo3/sysext/impexp/Tests/Functional/Fixtures/ImportExportXml/pages-and-ttcontent-with-image.xml

index 69c73fc..fa4c329 100644 (file)
@@ -2,7 +2,7 @@
 return array(
     'ctrl' => array(
         'title' => 'LLL:EXT:lang/locallang_tca.xlf:sys_file_reference',
-        'label' => 'uid',
+        'label' => 'uid_local',
         'formattedLabel_userFunc' => 'EXT:core/Classes/Resource/Service/UserFileInlineLabelService.php:TYPO3\\CMS\\Core\\Resource\\Service\\UserFileInlineLabelService->getInlineLabel',
         'formattedLabel_userFunc_options' => array(
             'sys_file' => array(
@@ -102,6 +102,7 @@ return array(
                 'type' => 'group',
                 'internal_type' => 'db',
                 'size' => 1,
+                'eval' => 'int',
                 'maxitems' => 1,
                 'minitems' => 0,
                 'allowed' => 'sys_file'
index 5b24bc2..947084d 100644 (file)
@@ -67,7 +67,7 @@
                                <rec index="1" type="array">
                                        <uid>1</uid>
                                        <pid>1</pid>
-                                       <title>1</title>
+                                       <title>typo3_image2.jpg</title>
                                        <size>297</size>
                                        <relations index="rels" type="array">
                                                <element index="sys_file:1" type="array">
index c9d3f8e..47889be 100644 (file)
@@ -67,7 +67,7 @@
                                <rec index="1" type="array">
                                        <uid>1</uid>
                                        <pid>1</pid>
-                                       <title>1</title>
+                                       <title>typo3_image2.jpg</title>
                                        <size>297</size>
                                        <relations index="rels" type="array">
                                                <element index="sys_file:1" type="array">