[!!!][TASK] Improve flex and TCA handling in FormEngine
[Packages/TYPO3.CMS.git] / typo3 / sysext / core / Configuration / TCA / sys_file_storage.php
1 <?php
2 return [
3 'ctrl' => [
4 'title' => 'LLL:EXT:lang/Resources/Private/Language/locallang_tca.xlf:sys_file_storage',
5 'label' => 'name',
6 'tstamp' => 'tstamp',
7 'crdate' => 'crdate',
8 'cruser_id' => 'cruser_id',
9 'default_sortby' => 'ORDER BY name',
10 'delete' => 'deleted',
11 'descriptionColumn' => 'description',
12 'rootLevel' => true,
13 'versioningWS_alwaysAllowLiveEdit' => true, // Only have LIVE records of file storages
14 'enablecolumns' => [],
15 'typeicon_classes' => [
16 'default' => 'mimetypes-x-sys_file_storage'
17 ],
18 'searchFields' => 'name,description'
19 ],
20 'interface' => [
21 'showRecordFieldList' => 'name,description,driver,processingfolder,configuration,auto_extract_metadata'
22 ],
23 'columns' => [
24 'name' => [
25 'label' => 'LLL:EXT:lang/Resources/Private/Language/locallang_tca.xlf:sys_file_storage.name',
26 'config' => [
27 'type' => 'input',
28 'size' => 30,
29 'eval' => 'required'
30 ]
31 ],
32 'description' => [
33 'label' => 'LLL:EXT:lang/Resources/Private/Language/locallang_tca.xlf:sys_file_storage.description',
34 'config' => [
35 'type' => 'text',
36 'cols' => 30,
37 'rows' => 5
38 ]
39 ],
40 'is_browsable' => [
41 'label' => 'LLL:EXT:lang/Resources/Private/Language/locallang_tca.xlf:sys_file_storage.is_browsable',
42 'config' => [
43 'type' => 'check',
44 'default' => 1
45 ]
46 ],
47 'is_default' => [
48 'label' => 'LLL:EXT:lang/Resources/Private/Language/locallang_tca.xlf:sys_file_storage.is_default',
49 'config' => [
50 'type' => 'check',
51 'default' => 0,
52 'eval' => 'maximumRecordsChecked',
53 'validation' => [
54 'maximumRecordsChecked' => 1
55 ]
56 ]
57 ],
58 'is_public' => [
59 'label' => 'LLL:EXT:lang/Resources/Private/Language/locallang_tca.xlf:sys_file_storage.is_public',
60 'config' => [
61 'default' => true,
62 'type' => 'user',
63 'userFunc' => \TYPO3\CMS\Core\Resource\Service\UserStorageCapabilityService::class . '->renderIsPublic',
64 ]
65 ],
66 'is_writable' => [
67 'label' => 'LLL:EXT:lang/Resources/Private/Language/locallang_tca.xlf:sys_file_storage.is_writable',
68 'config' => [
69 'type' => 'check',
70 'default' => 1
71 ]
72 ],
73 'is_online' => [
74 'label' => 'LLL:EXT:lang/Resources/Private/Language/locallang_tca.xlf:sys_file_storage.is_online',
75 'config' => [
76 'type' => 'check',
77 'default' => 1
78 ]
79 ],
80 'auto_extract_metadata' => [
81 'label' => 'LLL:EXT:lang/Resources/Private/Language/locallang_tca.xlf:sys_file_storage.auto_extract_metadata',
82 'config' => [
83 'type' => 'check',
84 'default' => 1
85 ]
86 ],
87 'processingfolder' => [
88 'label' => 'LLL:EXT:lang/Resources/Private/Language/locallang_tca.xlf:sys_file_storage.processingfolder',
89 'config' => [
90 'type' => 'input',
91 'placeholder' => 'LLL:EXT:lang/Resources/Private/Language/locallang_tca.xlf:sys_file_storage.processingfolder.placeholder',
92 'size' => 20
93 ]
94 ],
95 'driver' => [
96 'label' => 'LLL:EXT:lang/Resources/Private/Language/locallang_tca.xlf:sys_file_storage.driver',
97 'onChange' => 'reload',
98 'config' => [
99 'type' => 'select',
100 'renderType' => 'selectSingle',
101 'items' => [],
102 'default' => 'Local',
103 'onChange' => 'reload'
104 ]
105 ],
106 'configuration' => [
107 'label' => 'LLL:EXT:lang/Resources/Private/Language/locallang_tca.xlf:sys_file_storage.configuration',
108 'config' => [
109 'type' => 'flex',
110 'ds_pointerField' => 'driver',
111 'ds' => []
112 ],
113 ]
114 ],
115 'types' => [
116 '0' => ['showitem' => '
117 --div--;LLL:EXT:core/Resources/Private/Language/Form/locallang_tabs.xlf:general,
118 name, driver, configuration, is_default, auto_extract_metadata, processingfolder,
119 --div--;Access capabilities,
120 --palette--;Capabilities;capabilities,
121 --div--;LLL:EXT:core/Resources/Private/Language/Form/locallang_tabs.xlf:access,
122 is_online,
123 --div--;LLL:EXT:core/Resources/Private/Language/Form/locallang_tabs.xlf:notes,
124 description,
125 --div--;LLL:EXT:core/Resources/Private/Language/Form/locallang_tabs.xlf:extended,
126 ']
127 ],
128 'palettes' => [
129 'capabilities' => [
130 'showitem' => 'is_browsable, is_public, is_writable',
131 ],
132 ],
133 ];