[TASK] Change checkboxes in sys_workspace
[Packages/TYPO3.CMS.git] / typo3 / sysext / workspaces / Configuration / TCA / sys_workspace.php
1 <?php
2 return [
3 'ctrl' => [
4 'label' => 'title',
5 'tstamp' => 'tstamp',
6 'title' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_workspace',
7 'descriptionColumn' => 'description',
8 'adminOnly' => true,
9 'rootLevel' => 1,
10 'delete' => 'deleted',
11 'typeicon_classes' => [
12 'default' => 'mimetypes-x-sys_workspace'
13 ],
14 'versioningWS_alwaysAllowLiveEdit' => true
15 ],
16 'columns' => [
17 'title' => [
18 'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_general.xlf:LGL.title',
19 'config' => [
20 'type' => 'input',
21 'size' => 20,
22 'max' => 30,
23 'eval' => 'required,trim,unique'
24 ]
25 ],
26 'description' => [
27 'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_general.xlf:LGL.description',
28 'config' => [
29 'type' => 'text',
30 'rows' => 5,
31 'cols' => 30
32 ]
33 ],
34 'adminusers' => [
35 'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_workspace.adminusers',
36 'config' => [
37 'type' => 'group',
38 'internal_type' => 'db',
39 'allowed' => 'be_users,be_groups',
40 'prepend_tname' => true,
41 'size' => 3,
42 'maxitems' => 10,
43 'autoSizeMax' => 10,
44 ]
45 ],
46 'members' => [
47 'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_workspace.members',
48 'config' => [
49 'type' => 'group',
50 'internal_type' => 'db',
51 'allowed' => 'be_users,be_groups',
52 'prepend_tname' => true,
53 'size' => 3,
54 'maxitems' => 100,
55 'autoSizeMax' => 10,
56 ]
57 ],
58 'db_mountpoints' => [
59 'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:db_mountpoints',
60 'config' => [
61 'type' => 'group',
62 'internal_type' => 'db',
63 'allowed' => 'pages',
64 'size' => 3,
65 'maxitems' => 25,
66 'autoSizeMax' => 10,
67 ]
68 ],
69 'file_mountpoints' => [
70 'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:file_mountpoints',
71 'config' => [
72 'type' => 'select',
73 'renderType' => 'selectCheckBox',
74 'foreign_table' => 'sys_filemounts',
75 'foreign_table_where' => ' AND sys_filemounts.pid=0 ORDER BY sys_filemounts.title',
76 'size' => 3,
77 'maxitems' => 25,
78 'autoSizeMax' => 10,
79 ]
80 ],
81 'publish_time' => [
82 'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_workspace.publish_time',
83 'config' => [
84 'type' => 'input',
85 'renderType' => 'inputDateTime',
86 'eval' => 'datetime,int',
87 'default' => 0,
88 ]
89 ],
90 'unpublish_time' => [
91 'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_workspace.unpublish_time',
92 'config' => [
93 'type' => 'input',
94 'renderType' => 'inputDateTime',
95 'eval' => 'datetime,int',
96 'default' => 0,
97 'range' => [
98 'upper' => mktime(0, 0, 0, 1, 1, 2038)
99 ]
100 ],
101 ],
102 'freeze' => [
103 'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_workspace.freeze',
104 'config' => [
105 'type' => 'check',
106 'renderType' => 'checkboxToggle',
107 'default' => 0,
108 'items' => [
109 [
110 0 => '',
111 1 => '',
112 ]
113 ],
114 ]
115 ],
116 'live_edit' => [
117 'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_workspace.live_edit',
118 'config' => [
119 'type' => 'check',
120 'renderType' => 'checkboxToggle',
121 'default' => 0,
122 'items' => [
123 [
124 0 => '',
125 1 => '',
126 ]
127 ],
128 ]
129 ],
130 'swap_modes' => [
131 'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_workspace.swap_modes',
132 'config' => [
133 'type' => 'select',
134 'renderType' => 'selectSingle',
135 'items' => [
136 ['', 0],
137 ['Swap-Into-Workspace on Auto-publish', 1],
138 ['Disable Swap-Into-Workspace', 2]
139 ]
140 ]
141 ],
142 'publish_access' => [
143 'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_workspace.publish_access',
144 'config' => [
145 'type' => 'check',
146 'items' => [
147 ['Publish only content in publish stage', 0],
148 ['Only workspace owner can publish', 0]
149 ]
150 ]
151 ],
152 'stagechg_notification' => [
153 'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_workspace.stagechg_notification',
154 'config' => [
155 'type' => 'select',
156 'renderType' => 'selectSingle',
157 'items' => [
158 ['', 0],
159 ['Notify users on next stage only', 1],
160 ['Notify all users on any change', 10]
161 ]
162 ]
163 ],
164 'custom_stages' => [
165 'exclude' => true,
166 'label' => 'LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.custom_stages',
167 'config' => [
168 'type' => 'inline',
169 'foreign_table' => 'sys_workspace_stage',
170 'appearance' => 'useSortable,expandSingle',
171 'foreign_field' => 'parentid',
172 'foreign_table_field' => 'parenttable',
173 'minitems' => 0
174 ],
175 'default' => 0
176 ],
177 'edit_notification_defaults' => [
178 'label' => 'LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace_stage.notification_defaults',
179 'displayCond' => 'FIELD:edit_allow_notificaton_settings:BIT:1',
180 'config' => [
181 'type' => 'group',
182 'internal_type' => 'db',
183 'allowed' => 'be_users,be_groups',
184 'prepend_tname' => true,
185 'size' => 3,
186 'maxitems' => 100,
187 'autoSizeMax' => 20,
188 ]
189 ],
190 'edit_allow_notificaton_settings' => [
191 'label' => 'LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.settingsDialog',
192 'config' => [
193 'type' => 'check',
194 'items' => [
195 ['LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.settingsDialog.showDialog', ''],
196 ['LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.settingsDialog.changeablePreselection', ''],
197 ],
198 'default' => 3,
199 'cols' => 2,
200 ]
201 ],
202 'edit_notification_preselection' => [
203 'label' => 'LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.preselection',
204 'config' => [
205 'type' => 'check',
206 'items' => [
207 ['LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.preselection.owners', ''],
208 ['LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.preselection.members', ''],
209 ['LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.preselection.editors', ''],
210 ],
211 'default' => 2,
212 'cols' => 3,
213 ]
214 ],
215 'publish_notification_defaults' => [
216 'label' => 'LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace_stage.notification_defaults',
217 'displayCond' => 'FIELD:publish_allow_notificaton_settings:BIT:1',
218 'config' => [
219 'type' => 'group',
220 'internal_type' => 'db',
221 'allowed' => 'be_users,be_groups',
222 'prepend_tname' => true,
223 'size' => 3,
224 'maxitems' => 100,
225 'autoSizeMax' => 20,
226 ]
227 ],
228 'publish_allow_notificaton_settings' => [
229 'label' => 'LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.settingsDialog',
230 'config' => [
231 'type' => 'check',
232 'items' => [
233 ['LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.settingsDialog.showDialog', ''],
234 ['LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.settingsDialog.changeablePreselection', ''],
235 ],
236 'default' => 3,
237 'cols' => 2,
238 ]
239 ],
240 'publish_notification_preselection' => [
241 'label' => 'LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.preselection',
242 'config' => [
243 'type' => 'check',
244 'items' => [
245 ['LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.preselection.owners', ''],
246 ['LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.preselection.members', ''],
247 ['LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.preselection.editors', ''],
248 ],
249 'default' => 1,
250 'cols' => 3,
251 ]
252 ],
253 'execute_notification_defaults' => [
254 'label' => 'LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace_stage.notification_defaults',
255 'displayCond' => 'FIELD:execute_allow_notificaton_settings:BIT:1',
256 'config' => [
257 'type' => 'group',
258 'internal_type' => 'db',
259 'allowed' => 'be_users,be_groups',
260 'prepend_tname' => true,
261 'size' => 3,
262 'maxitems' => 100,
263 'autoSizeMax' => 20,
264 ]
265 ],
266 'execute_allow_notificaton_settings' => [
267 'label' => 'LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.settingsDialog',
268 'config' => [
269 'type' => 'check',
270 'items' => [
271 ['LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.settingsDialog.showDialog', ''],
272 ['LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.settingsDialog.changeablePreselection', ''],
273 ],
274 'default' => 3,
275 'cols' => 2,
276 ]
277 ],
278 'execute_notification_preselection' => [
279 'label' => 'LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.preselection',
280 'config' => [
281 'type' => 'check',
282 'items' => [
283 ['LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.preselection.owners', ''],
284 ['LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.preselection.members', ''],
285 ['LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.preselection.editors', ''],
286 ],
287 'default' => 3,
288 'cols' => 3,
289 ]
290 ]
291 ],
292 'palettes' => [
293 'stage.edit' => [
294 'label' => 'LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.palette.stage.edit',
295 'showitem' => 'edit_allow_notificaton_settings, edit_notification_preselection,',
296 ],
297 'stage.publish' => [
298 'label' => 'LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.palette.stage.publish',
299 'showitem' => 'publish_allow_notificaton_settings, publish_notification_preselection,',
300 ],
301 'stage.execute' => [
302 'label' => 'LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_workspace.palette.stage.execute',
303 'showitem' => 'execute_allow_notificaton_settings, execute_notification_preselection,',
304 ]
305 ],
306 'types' => [
307 '0' => ['showitem' => '
308 --div--;LLL:EXT:core/Resources/Private/Language/Form/locallang_tabs.xlf:general,
309 title,
310 --div--;LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_filemounts.tabs.users,
311 adminusers,members,
312 --div--;LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:tabs.notification_settings,
313 stagechg_notification,
314 --palette--;;stage.edit, edit_notification_defaults,
315 --palette--;;stage.publish, publish_notification_defaults,
316 --palette--;;stage.execute, execute_notification_defaults,
317 --div--;LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_filemounts.tabs.mountpoints,
318 db_mountpoints,file_mountpoints,
319 --div--;LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_filemounts.tabs.publishing,
320 publish_time,
321 --div--;LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xlf:sys_filemounts.tabs.staging,
322 custom_stages,
323 --div--;LLL:EXT:core/Resources/Private/Language/Form/locallang_tabs.xlf:access,
324 freeze,live_edit,swap_modes,publish_access,
325 --div--;LLL:EXT:core/Resources/Private/Language/Form/locallang_tabs.xlf:notes,
326 description,
327 --div--;LLL:EXT:core/Resources/Private/Language/Form/locallang_tabs.xlf:extended,
328 ']
329 ]
330 ];