ee15c0833f7a9517d020d1d53adc8ca2dbc8243c
[Packages/TYPO3.CMS.git] / typo3 / sysext / core / Configuration / TCA / sys_file_collection.php
1 <?php
2 return array(
3 'ctrl' => array(
4 'title' => 'LLL:EXT:lang/locallang_tca.xlf:sys_file_collection',
5 'label' => 'title',
6 'tstamp' => 'tstamp',
7 'crdate' => 'crdate',
8 'cruser_id' => 'cruser_id',
9 'versioningWS' => TRUE,
10 'origUid' => 't3_origuid',
11 'languageField' => 'sys_language_uid',
12 'transOrigPointerField' => 'l10n_parent',
13 'transOrigDiffSourceField' => 'l10n_diffsource',
14 'default_sortby' => 'ORDER BY crdate',
15 'delete' => 'deleted',
16 'rootlevel' => -1,
17 'type' => 'type',
18 'typeicon_column' => 'type',
19 'typeicon_classes' => array(
20 'default' => 'apps-filetree-folder-media',
21 'static' => 'apps-clipboard-images',
22 'folder' => 'apps-filetree-folder-media'
23 ),
24 'requestUpdate' => 'storage',
25 'enablecolumns' => array(
26 'disabled' => 'hidden',
27 'starttime' => 'starttime',
28 'endtime' => 'endtime'
29 ),
30 'searchFields' => 'files,title'
31 ),
32 'interface' => array(
33 'showRecordFieldList' => 'sys_language_uid,l10n_parent,l10n_diffsource,hidden,starttime,endtime,files,title'
34 ),
35 'columns' => array(
36 't3ver_label' => array(
37 'label' => 'LLL:EXT:lang/locallang_general.xlf:LGL.versionLabel',
38 'config' => array(
39 'type' => 'input',
40 'size' => '30',
41 'max' => '30'
42 )
43 ),
44 'sys_language_uid' => array(
45 'exclude' => 1,
46 'label' => 'LLL:EXT:lang/locallang_general.xlf:LGL.language',
47 'config' => array(
48 'type' => 'select',
49 'foreign_table' => 'sys_language',
50 'foreign_table_where' => 'ORDER BY sys_language.title',
51 'items' => array(
52 array('LLL:EXT:lang/locallang_general.xlf:LGL.allLanguages', -1),
53 array('LLL:EXT:lang/locallang_general.xlf:LGL.default_value', 0)
54 )
55 )
56 ),
57 'l10n_parent' => array(
58 'displayCond' => 'FIELD:sys_language_uid:>:0',
59 'exclude' => 1,
60 'label' => 'LLL:EXT:lang/locallang_general.xlf:LGL.l18n_parent',
61 'config' => array(
62 'type' => 'select',
63 'items' => array(
64 array('', 0)
65 ),
66 'foreign_table' => 'sys_file_collection',
67 'foreign_table_where' => 'AND sys_file_collection.pid=###CURRENT_PID### AND sys_file_collection.sys_language_uid IN (-1,0)'
68 )
69 ),
70 'l10n_diffsource' => array(
71 'config' => array(
72 'type' => 'passthrough'
73 )
74 ),
75 'hidden' => array(
76 'exclude' => 1,
77 'label' => 'LLL:EXT:lang/locallang_general.xlf:LGL.hidden',
78 'config' => array(
79 'type' => 'check',
80 'default' => '0'
81 )
82 ),
83 'starttime' => array(
84 'exclude' => 1,
85 'label' => 'LLL:EXT:lang/locallang_general.xlf:LGL.starttime',
86 'config' => array(
87 'type' => 'input',
88 'size' => '8',
89 'max' => '20',
90 'eval' => 'date',
91 'default' => '0',
92 'checkbox' => '0'
93 )
94 ),
95 'endtime' => array(
96 'exclude' => 1,
97 'label' => 'LLL:EXT:lang/locallang_general.xlf:LGL.endtime',
98 'config' => array(
99 'type' => 'input',
100 'size' => '8',
101 'max' => '20',
102 'eval' => 'date',
103 'checkbox' => '0',
104 'default' => '0',
105 'range' => array(
106 'upper' => mktime(0, 0, 0, 1, 1, 2038),
107 )
108 )
109 ),
110 'type' => array(
111 'exclude' => 0,
112 'label' => 'LLL:EXT:lang/locallang_tca.xlf:sys_file_collection.type',
113 'config' => array(
114 'type' => 'select',
115 'items' => array(
116 array('LLL:EXT:lang/locallang_tca.xlf:sys_file_collection.type.0', 'static'),
117 array('LLL:EXT:lang/locallang_tca.xlf:sys_file_collection.type.1', 'folder'),
118 array('LLL:EXT:lang/locallang_tca.xlf:sys_file_collection.type.2', 'category')
119 )
120 )
121 ),
122 'files' => array(
123 'exclude' => 0,
124 'label' => 'LLL:EXT:lang/locallang_tca.xlf:sys_file_collection.files',
125 'config' => \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getFileFieldTCAConfig('files')
126 ),
127 'title' => array(
128 'exclude' => 0,
129 'label' => 'LLL:EXT:lang/locallang_tca.xlf:sys_file_collection.title',
130 'config' => array(
131 'type' => 'input',
132 'size' => '30',
133 'eval' => 'required'
134 )
135 ),
136 'storage' => array(
137 'exclude' => 0,
138 'label' => 'LLL:EXT:lang/locallang_tca.xlf:sys_file_collection.storage',
139 'config' => array(
140 'type' => 'select',
141 'items' => array(
142 array('', 0)
143 ),
144 'foreign_table' => 'sys_file_storage',
145 'foreign_table_where' => 'ORDER BY sys_file_storage.name',
146 'size' => 1,
147 'minitems' => 0,
148 'maxitems' => 1
149 )
150 ),
151 'folder' => array(
152 'exclude' => 0,
153 'label' => 'LLL:EXT:lang/locallang_tca.xlf:sys_file_collection.folder',
154 'config' => array(
155 'type' => 'select',
156 'items' => array(),
157 'itemsProcFunc' => 'typo3/sysext/core/Classes/Resource/Service/UserFileMountService.php:TYPO3\CMS\Core\Resource\Service\UserFileMountService->renderTceformsSelectDropdown',
158 )
159 ),
160 'category' => array(
161 'exclude' => 0,
162 'label' => 'LLL:EXT:lang/locallang_tca.xlf:sys_file_collection.category',
163 'config' => array(
164 'minitems' => 0,
165 'maxitems' => 1,
166 'type' => 'select',
167 'renderMode' => 'tree',
168 'foreign_table' => 'sys_category',
169 'foreign_table_where' => ' AND sys_category.sys_language_uid IN (-1,0) ORDER BY sys_category.sorting ASC',
170 'treeConfig' => array(
171 'parentField' => 'parent',
172 'appearance' => array(
173 'expandAll' => TRUE,
174 'showHeader' => TRUE,
175 )
176 )
177 )
178 )
179 ),
180 'types' => array(
181 '0' => array('showitem' => 'sys_language_uid;;;;1-1-1, l10n_parent, l10n_diffsource, title;;1, type, files'),
182 'static' => array('showitem' => 'sys_language_uid;;;;1-1-1, l10n_parent, l10n_diffsource, title;;1, type, files'),
183 'folder' => array('showitem' => 'sys_language_uid;;;;1-1-1, l10n_parent, l10n_diffsource, title;;1, type, storage, folder'),
184 'category' => array('showitem' => 'sys_language_uid;;;;1-1-1, l10n_parent, l10n_diffsource, title;;1, type, category')
185 ),
186 'palettes' => array(
187 '1' => array('showitem' => 'hidden, starttime, endtime')
188 )
189 );