‪TYPO3CMS  9.5
tx_blogexample_domain_model_post.php
Go to the documentation of this file.
1 <?php
2 return [
3  'ctrl' => [
4  'title' => 'LLL:EXT:blog_example/Resources/Private/Language/locallang_db.xml:tx_blogexample_domain_model_post',
5  'label' => 'title',
6  'label_alt' => 'author',
7  'label_alt_force' => true,
8  'tstamp' => 'tstamp',
9  'crdate' => 'crdate',
10  'versioningWS' => true,
11  'origUid' => 't3_origuid',
12  'languageField' => 'sys_language_uid',
13  'transOrigPointerField' => 'l18n_parent',
14  'transOrigDiffSourceField' => 'l18n_diffsource',
15  'delete' => 'deleted',
16  'sortby' => 'sorting',
17  'enablecolumns' => [
18  'disabled' => 'hidden'
19  ],
20  'iconfile' => 'EXT:blog_example/Resources/Public/Icons/icon_tx_blogexample_domain_model_post.gif'
21  ],
22  'interface' => [
23  'showRecordFieldList' => 'title, date, author',
24  'maxDBListItems' => 100,
25  'maxSingleDBListItems' => 500
26  ],
27  'types' => [
28  '1' => ['showitem' => 'sys_language_uid, hidden, blog, title, date, author, second_author, content, tags, comments, related_posts, additional_name, additional_info, additional_comments']
29  ],
30  'columns' => [
31  'sys_language_uid' => [
32  'exclude' => true,
33  'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_general.xlf:LGL.language',
34  'config' => [
35  'type' => 'select',
36  'renderType' => 'selectSingle',
37  'special' => 'languages',
38  'items' => [
39  [
40  'LLL:EXT:core/Resources/Private/Language/locallang_general.xlf:LGL.allLanguages',
41  -1,
42  'flags-multiple'
43  ],
44  ],
45  'default' => 0
46  ]
47  ],
48  'l18n_parent' => [
49  'displayCond' => 'FIELD:sys_language_uid:>:0',
50  'exclude' => true,
51  'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_general.xlf:LGL.l18n_parent',
52  'config' => [
53  'type' => 'select',
54  'renderType' => 'selectSingle',
55  'items' => [
56  ['', 0],
57  ],
58  'foreign_table' => 'tx_blogexample_domain_model_post',
59  'foreign_table_where' => 'AND tx_blogexample_domain_model_post.uid=###REC_FIELD_l18n_parent### AND tx_blogexample_domain_model_post.sys_language_uid IN (-1,0)',
60  ]
61  ],
62  'l18n_diffsource' => [
63  'config' => [
64  'type' => 'passthrough',
65  'default' => ''
66  ]
67  ],
68  'hidden' => [
69  'exclude' => true,
70  'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_general.xlf:LGL.hidden',
71  'config' => [
72  'type' => 'check'
73  ]
74  ],
75  'blog' => [
76  'exclude' => true,
77  'label' => 'LLL:EXT:blog_example/Resources/Private/Language/locallang_db.xml:tx_blogexample_domain_model_post.blog',
78  'config' => [
79  'type' => 'select',
80  'renderType' => 'selectSingle',
81  'foreign_table' => 'tx_blogexample_domain_model_blog',
82  'maxitems' => 1,
83  ]
84  ],
85  'title' => [
86  'label' => 'LLL:EXT:blog_example/Resources/Private/Language/locallang_db.xml:tx_blogexample_domain_model_post.title',
87  'config' => [
88  'type' => 'input',
89  'size' => 20,
90  'eval' => 'trim, required',
91  'max' => 256
92  ]
93  ],
94  'date' => [
95  'exclude' => true,
96  'label' => 'LLL:EXT:blog_example/Resources/Private/Language/locallang_db.xml:tx_blogexample_domain_model_post.date',
97  'config' => [
98  'type' => 'input',
99  'renderType' => 'inputDateTime',
100  'size' => 12,
101  'eval' => 'datetime, required',
102  'default' => time()
103  ]
104  ],
105  'author' => [
106  'exclude' => true,
107  'label' => 'LLL:EXT:blog_example/Resources/Private/Language/locallang_db.xml:tx_blogexample_domain_model_post.author',
108  'config' => [
109  'type' => 'select',
110  'renderType' => 'selectSingle',
111  'foreign_table' => 'tx_blogexample_domain_model_person',
112  'fieldControl' => [
113  'editPopup' => [
114  'disabled' => false,
115  ],
116  'addRecord' => [
117  'disabled' => false,
118  'options' => [
119  'setValue' => 'prepend',
120  ],
121  ],
122  ],
123  ],
124  ],
125  'second_author' => [
126  'exclude' => true,
127  'label' => 'LLL:EXT:blog_example/Resources/Private/Language/locallang_db.xml:tx_blogexample_domain_model_post.second_author',
128  'config' => [
129  'type' => 'group',
130  'internal_type' => 'db',
131  'allowed' => 'tx_blogexample_domain_model_person',
132  'foreign_table' => 'tx_blogexample_domain_model_person',
133  'maxitems' => 1,
134  'fieldControl' => [
135  'editPopup' => [
136  'disabled' => false,
137  ],
138  'addRecord' => [
139  'disabled' => false,
140  ],
141  'listModule' => [
142  'disabled' => false,
143  ],
144  ],
145  ],
146  ],
147  'reviewer' => [
148  'exclude' => true,
149  'label' => 'LLL:EXT:blog_example/Resources/Private/Language/locallang_db.xml:tx_blogexample_domain_model_post.reviewer',
150  'config' => [
151  'type' => 'select',
152  'renderType' => 'selectSingle',
153  'foreign_table' => 'tx_blogexample_domain_model_person',
154  'fieldControl' => [
155  'editPopup' => [
156  'disabled' => false,
157  ],
158  'addRecord' => [
159  'disabled' => false,
160  'options' => [
161  'setValue' => 'prepend',
162  ],
163  ],
164  ],
165  ],
166  ],
167  'content' => [
168  'exclude' => true,
169  'label' => 'LLL:EXT:blog_example/Resources/Private/Language/locallang_db.xml:tx_blogexample_domain_model_post.content',
170  'config' => [
171  'type' => 'text',
172  'rows' => 30,
173  'cols' => 80
174  ]
175  ],
176  'tags' => [
177  'exclude' => true,
178  'label' => 'LLL:EXT:blog_example/Resources/Private/Language/locallang_db.xml:tx_blogexample_domain_model_post.tags',
179  'config' => [
180  'type' => 'inline',
181  'foreign_table' => 'tx_blogexample_domain_model_tag',
182  'MM' => 'tx_blogexample_post_tag_mm',
183  'appearance' => [
184  'useCombination' => 1,
185  'useSortable' => 1,
186  'collapseAll' => 1,
187  'expandSingle' => 1,
188  ]
189  ]
190  ],
191  'comments' => [
192  'exclude' => true,
193  'label' => 'LLL:EXT:blog_example/Resources/Private/Language/locallang_db.xml:tx_blogexample_domain_model_post.comments',
194  'config' => [
195  'type' => 'inline',
196  'foreign_table' => 'tx_blogexample_domain_model_comment',
197  'foreign_field' => 'post',
198  'size' => 10,
199  'autoSizeMax' => 30,
200  'multiple' => 0,
201  'appearance' => [
202  'collapseAll' => 1,
203  'expandSingle' => 1,
204  ]
205  ]
206  ],
207  'related_posts' => [
208  'exclude' => true,
209  'label' => 'LLL:EXT:blog_example/Resources/Private/Language/locallang_db.xml:tx_blogexample_domain_model_post.related',
210  'config' => [
211  'type' => 'select',
212  'renderType' => 'selectMultipleSideBySide',
213  'size' => 10,
214  'autoSizeMax' => 30,
215  'multiple' => 0,
216  'foreign_table' => 'tx_blogexample_domain_model_post',
217  'foreign_table_where' => 'AND ###THIS_UID### != tx_blogexample_domain_model_post.uid',
218  'MM' => 'tx_blogexample_post_post_mm',
219  'MM_opposite_field' => 'related_posts',
220  ]
221  ],
222  'additional_name' => [
223  'exclude' => true,
224  'label' => 'LLL:EXT:blog_example/Resources/Private/Language/locallang_db.xml:tx_blogexample_domain_model_post.additional_name',
225  'config' => [
226  'type' => 'inline', // this will store the info uid in the additional_name field (CSV)
227  'foreign_table' => 'tx_blogexample_domain_model_info',
228  'minitems' => 0,
229  'maxitems' => 1,
230  ],
231  ],
232  'additional_info' => [
233  'exclude' => true,
234  'label' => 'LLL:EXT:blog_example/Resources/Private/Language/locallang_db.xml:tx_blogexample_domain_model_post.additional_info',
235  'config' => [
236  'type' => 'inline', // this will store the post uid in the post field of the info table
237  'foreign_table' => 'tx_blogexample_domain_model_info',
238  'foreign_field' => 'post',
239  'minitems' => 0,
240  'maxitems' => 1,
241  ],
242  ],
243  'additional_comments' => [
244  'exclude' => true,
245  'label' => 'LLL:EXT:blog_example/Resources/Private/Language/locallang_db.xml:tx_blogexample_domain_model_post.additional_comments',
246  'config' => [
247  'type' => 'inline', // this will store the comments uids in the additional_comments field (CSV)
248  'foreign_table' => 'tx_blogexample_domain_model_comment',
249  'minitems' => 0,
250  'maxitems' => 200,
251  ],
252  ],
253  ]
254 ];