‪TYPO3CMS  10.4
sys_file_reference.php
Go to the documentation of this file.
1 <?php
2 
3 return [
4  'ctrl' => [
5  'title' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference',
6  'label' => 'uid_local',
7  'formattedLabel_userFunc' => 'TYPO3\\CMS\\Core\\Resource\\Service\\UserFileInlineLabelService->getInlineLabel',
8  'formattedLabel_userFunc_options' => [
9  'sys_file' => [
10  'title',
11  'name'
12  ]
13  ],
14  'tstamp' => 'tstamp',
15  'crdate' => 'crdate',
16  'cruser_id' => 'cruser_id',
17  'type' => 'uid_local:type',
18  'hideTable' => true,
19  'delete' => 'deleted',
20  'versioningWS' => true,
21  'languageField' => 'sys_language_uid',
22  'transOrigPointerField' => 'l10n_parent',
23  'transOrigDiffSourceField' => 'l10n_diffsource',
24  'rootLevel' => -1,
25  // records can and should be edited in workspaces
26  'shadowColumnsForMovePlaceholders' => 'tablenames,fieldname,uid_local,table_local,uid_foreign',
27  'enablecolumns' => [
28  'disabled' => 'hidden'
29  ],
30  'typeicon_classes' => [
31  'default' => 'mimetypes-other-other'
32  ],
33  'security' => [
34  'ignoreWebMountRestriction' => true,
35  'ignoreRootLevelRestriction' => true,
36  ],
37  'searchFields' => 'uid_local,uid_foreign,tablenames,fieldname,title,description'
38  ],
39  'columns' => [
40  'sys_language_uid' => [
41  'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_general.xlf:LGL.language',
42  'config' => [
43  'type' => 'select',
44  'renderType' => 'selectSingle',
45  'foreign_table' => 'sys_language',
46  'items' => [
47  ['LLL:EXT:core/Resources/Private/Language/locallang_general.xlf:LGL.allLanguages', -1],
48  ['LLL:EXT:core/Resources/Private/Language/locallang_general.xlf:LGL.default_value', 0]
49  ],
50  'default' => 0,
51  'fieldWizard' => [
52  'selectIcons' => [
53  'disabled' => false,
54  ],
55  ],
56  ]
57  ],
58  'l10n_parent' => [
59  'displayCond' => 'FIELD:sys_language_uid:>:0',
60  'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_general.xlf:LGL.l18n_parent',
61  'config' => [
62  'type' => 'group',
63  'internal_type' => 'db',
64  'allowed' => 'sys_file_reference',
65  'size' => 1,
66  'maxitems' => 1,
67  'minitems' => 0,
68  'default' => 0
69  ]
70  ],
71  'l10n_diffsource' => [
72  'config' => [
73  'type' => 'passthrough',
74  'default' => ''
75  ]
76  ],
77  'hidden' => [
78  'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_general.xlf:LGL.hidden',
79  'config' => [
80  'type' => 'check',
81  'default' => 0
82  ]
83  ],
84  'uid_local' => [
85  'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.uid_local',
86  'config' => [
87  'type' => 'group',
88  'internal_type' => 'db',
89  'size' => 1,
90  'eval' => 'int',
91  'maxitems' => 1,
92  'minitems' => 0,
93  'allowed' => 'sys_file',
94  'hideSuggest' => true,
95  ]
96  ],
97  'uid_foreign' => [
98  'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.uid_foreign',
99  'config' => [
100  'type' => 'input',
101  'size' => 10,
102  'eval' => 'int'
103  ]
104  ],
105  'tablenames' => [
106  'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.tablenames',
107  'config' => [
108  'type' => 'input',
109  'size' => 30,
110  'eval' => 'trim'
111  ]
112  ],
113  'fieldname' => [
114  'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.fieldname',
115  'config' => [
116  'type' => 'input',
117  'size' => 30
118  ]
119  ],
120  'sorting_foreign' => [
121  'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.sorting_foreign',
122  'config' => [
123  'type' => 'input',
124  'size' => 4,
125  'max' => 4,
126  'eval' => 'int',
127  'default' => 0
128  ]
129  ],
130  'table_local' => [
131  'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.table_local',
132  'config' => [
133  'type' => 'input',
134  'size' => 20,
135  'default' => 'sys_file'
136  ]
137  ],
138  'title' => [
139  'l10n_mode' => 'prefixLangTitle',
140  'exclude' => true,
141  'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.title',
142  'config' => [
143  'type' => 'input',
144  'size' => 20,
145  'max' => 255,
146  'eval' => 'null',
147  'placeholder' => '__row|uid_local|metadata|title',
148  'mode' => 'useOrOverridePlaceholder',
149  'default' => null,
150  ]
151  ],
152  'link' => [
153  'exclude' => true,
154  'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.link',
155  'config' => [
156  'type' => 'input',
157  'renderType' => 'inputLink',
158  'size' => 20,
159  'max' => 1024,
160  'fieldControl' => [
161  'linkPopup' => [
162  'options' => [
163  'title' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.link',
164  ],
165  ],
166  ],
167  'softref' => 'typolink'
168  ]
169  ],
170  'description' => [
171  // This is used for captions in the frontend
172  'l10n_mode' => 'prefixLangTitle',
173  'exclude' => true,
174  'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.description',
175  'config' => [
176  'type' => 'text',
177  'cols' => 20,
178  'rows' => 5,
179  'eval' => 'null',
180  'placeholder' => '__row|uid_local|metadata|description',
181  'mode' => 'useOrOverridePlaceholder',
182  'default' => null,
183  ]
184  ],
185  'alternative' => [
186  'l10n_mode' => 'prefixLangTitle',
187  'exclude' => true,
188  'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.alternative',
189  'description' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file.alternative.description',
190  'config' => [
191  'type' => 'input',
192  'size' => 20,
193  'eval' => 'null',
194  'placeholder' => '__row|uid_local|metadata|alternative',
195  'mode' => 'useOrOverridePlaceholder',
196  'default' => null,
197  ],
198  ],
199  'crop' => [
200  'exclude' => true,
201  'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.crop',
202  'config' => [
203  'type' => 'imageManipulation'
204  ]
205  ],
206  'autoplay' => [
207  'exclude' => true,
208  'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.autoplay',
209  'config' => [
210  'type' => 'check',
211  'renderType' => 'checkboxToggle',
212  'default' => 0,
213  'items' => [
214  [
215  0 => '',
216  1 => '',
217  ]
218  ],
219  ]
220  ],
221  ],
222  'types' => [
223  // Note that at the moment we define the same fields for every media type.
224  // We leave the extensive definition of each type here anyway, to make clear that you can use it to differentiate between the types.
225  '0' => [
226  'showitem' => '
227  --palette--;;basicoverlayPalette,
228  --palette--;;filePalette'
229  ],
231  'showitem' => '
232  --palette--;;basicoverlayPalette,
233  --palette--;;filePalette'
234  ],
236  'showitem' => '
237  --palette--;;basicoverlayPalette,
238  --palette--;;filePalette'
239  ],
241  'showitem' => '
242  --palette--;;basicoverlayPalette,
243  --palette--;;filePalette'
244  ],
246  'showitem' => '
247  --palette--;;basicoverlayPalette,
248  --palette--;;filePalette'
249  ],
251  'showitem' => '
252  --palette--;;basicoverlayPalette,
253  --palette--;;filePalette'
254  ]
255  ],
256  'palettes' => [
257  // Used for basic overlays: having a filelist etc
258  'basicoverlayPalette' => [
259  'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.basicoverlayPalette',
260  'showitem' => 'title,description',
261  ],
262  // Used for everything that is an image (because it has a link and an alternative text)
263  'imageoverlayPalette' => [
264  'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.imageoverlayPalette',
265  'showitem' => '
266  alternative,description,--linebreak--,
267  link,title,--linebreak--,crop
268  ',
269  ],
270  // Used for everything that is a video
271  'videoOverlayPalette' => [
272  'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.videoOverlayPalette',
273  'showitem' => '
274  title,description,--linebreak--,autoplay
275  ',
276  ],
277  // Used for everything that is an audio file
278  'audioOverlayPalette' => [
279  'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.audioOverlayPalette',
280  'showitem' => '
281  title,description,--linebreak--,autoplay
282  ',
283  ],
284  // File palette, hidden but needs to be included all the time
285  'filePalette' => [
286  'showitem' => 'uid_local, hidden, sys_language_uid, l10n_parent',
287  'isHiddenPalette' => true,
288  ],
289  ],
290 ];
‪TYPO3\CMS\Core\Resource\AbstractFile\FILETYPE_VIDEO
‪const FILETYPE_VIDEO
Definition: AbstractFile.php:90
‪TYPO3\CMS\Core\Resource\AbstractFile\FILETYPE_IMAGE
‪const FILETYPE_IMAGE
Definition: AbstractFile.php:78
‪TYPO3\CMS\Core\Resource\AbstractFile\FILETYPE_AUDIO
‪const FILETYPE_AUDIO
Definition: AbstractFile.php:84
‪TYPO3\CMS\Core\Resource\AbstractFile\FILETYPE_TEXT
‪const FILETYPE_TEXT
Definition: AbstractFile.php:72
‪TYPO3\CMS\Core\Resource\AbstractFile\FILETYPE_APPLICATION
‪const FILETYPE_APPLICATION
Definition: AbstractFile.php:96