8680eae2a630ecd4f7d01ae618320ebbfde1e742
[TYPO3CMS/Extensions/static_info_tables.git] / Configuration / TCA / static_countries.php
1 <?php
2 // Country reference data from ISO 3166-1
3 return array(
4 'ctrl' => array(
5 'label' => 'cn_short_en',
6 'label_alt' => 'cn_iso_2',
7 'label_alt_force' => 1,
8 'label_userFunc' => 'SJBR\\StaticInfoTables\\Hook\\Backend\\Form\\FormDataProvider\\TcaLabelProcessor->addIsoCodeToLabel',
9 'adminOnly' => 1,
10 'rootLevel' => 1,
11 'is_static' => 1,
12 'readOnly' => 1,
13 'default_sortby' => 'ORDER BY cn_short_en',
14 'delete' => 'deleted',
15 'title' => 'LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries.title',
16 'iconfile' => 'EXT:static_info_tables/Resources/Public/Images/Icons/icon_static_countries.gif',
17 'searchFields' => 'cn_short_en,cn_official_name_local,cn_official_name_en'
18 ),
19 'interface' => array(
20 'showRecordFieldList' => 'cn_iso_2,cn_iso_3,cn_iso_nr,cn_official_name_local,cn_official_name_en,cn_capital,cn_tldomain,cn_currency_iso_3,cn_currency_iso_nr,cn_phone,cn_uno_member,cn_eu_member,cn_address_format,cn_short_en'
21 ),
22 'columns' => array(
23 'deleted' => array(
24 'readonly' => 1,
25 'label' => 'LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:deleted',
26 'config' => array(
27 'type' => 'check'
28 )
29 ),
30 'cn_iso_2' => array(
31 'label' => 'LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_iso_2',
32 'exclude' => '0',
33 'config' => array(
34 'type' => 'input',
35 'size' => '4',
36 'max' => '2',
37 'eval' => '',
38 'default' => ''
39 )
40 ),
41 'cn_iso_3' => array(
42 'label' => 'LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_iso_3',
43 'exclude' => '0',
44 'config' => array(
45 'type' => 'input',
46 'size' => '5',
47 'max' => '3',
48 'eval' => '',
49 'default' => ''
50 )
51 ),
52 'cn_iso_nr' => array(
53 'label' => 'LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_iso_nr',
54 'exclude' => '0',
55 'config' => array(
56 'type' => 'input',
57 'size' => '7',
58 'max' => '7',
59 'eval' => 'int',
60 'default' => '0'
61 )
62 ),
63 'cn_parent_territory_uid' => array(
64 'exclude' => 0,
65 'label' => 'LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_parent_territory_uid',
66 'config' => array(
67 'type' => 'select',
68 'items' => array(
69 array('', 0),
70 ),
71 'foreign_table' => 'static_territories',
72 'foreign_table_where' => 'ORDER BY static_territories.tr_name_en',
73 'itemsProcFunc' => 'SJBR\\StaticInfoTables\\Hook\\Backend\\Form\\FormDataProvider\\TcaSelectItemsProcessor->translateTerritoriesSelector',
74 'noIconsBelowSelect' => 1,
75 'size' => 1,
76 'minitems' => 0,
77 'maxitems' => 1,
78 )
79 ),
80 'cn_parent_tr_iso_nr' => array(
81 'config' => array(
82 'type' => 'passthrough',
83 )
84 ),
85 'cn_official_name_local' => array(
86 'label' => 'LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_official_name_local',
87 'exclude' => '0',
88 'config' => array(
89 'type' => 'input',
90 'size' => '25',
91 'max' => '128',
92 'eval' => 'trim',
93 'default' => '',
94 '_is_string' => '1'
95 )
96 ),
97 'cn_official_name_en' => array(
98 'label' => 'LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_official_name_en',
99 'exclude' => '0',
100 'config' => array(
101 'type' => 'input',
102 'size' => '25',
103 'max' => '50',
104 'eval' => 'trim',
105 'default' => '',
106 '_is_string' => '1'
107 )
108 ),
109 'cn_capital' => array(
110 'label' => 'LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_capital',
111 'exclude' => '0',
112 'config' => array(
113 'type' => 'input',
114 'size' => '15',
115 'max' => '45',
116 'eval' => 'trim',
117 'default' => '',
118 '_is_string' => '1'
119 )
120 ),
121 'cn_tldomain' => array(
122 'label' => 'LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_tldomain',
123 'exclude' => '0',
124 'config' => array(
125 'type' => 'input',
126 'size' => '5',
127 'max' => '',
128 'eval' => '',
129 'default' => ''
130 )
131 ),
132 'cn_currency_uid' => array(
133 'exclude' => 0,
134 'label' => 'LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_currency_uid',
135 'config' => array(
136 'type' => 'select',
137 'items' => array(
138 array('', 0),
139 ),
140 'foreign_table' => 'static_currencies',
141 'foreign_table_where' => 'ORDER BY static_currencies.cu_name_en',
142 'itemsProcFunc' => 'SJBR\\StaticInfoTables\\Hook\\Backend\\Form\\FormDataProvider\\TcaSelectItemsProcessor->translateCurrenciesSelector',
143 'noIconsBelowSelect' => 1,
144 'size' => 1,
145 'minitems' => 0,
146 'maxitems' => 1,
147 'wizards' => array(
148 'suggest' => array(
149 'type' => 'suggest',
150 'default' => array(
151 'receiverClass' => 'SJBR\\StaticInfoTables\\Hook\\Backend\\Form\\Wizard\\SuggestReceiver'
152 )
153 )
154 )
155 )
156 ),
157 'cn_currency_iso_nr' => array(
158 'config' => array(
159 'type' => 'passthrough',
160 )
161 ),
162 'cn_currency_iso_3' => array(
163 'config' => array(
164 'type' => 'passthrough',
165 )
166 ),
167 'cn_phone' => array(
168 'label' => 'LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_phone',
169 'exclude' => '0',
170 'config' => array(
171 'type' => 'input',
172 'size' => '10',
173 'max' => '20',
174 'eval' => '',
175 'default' => '0'
176 )
177 ),
178 'cn_eu_member' => array(
179 'label' => 'LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_eu_member',
180 'exclude' => '0',
181 'config' => array(
182 'type' => 'check',
183 'default' => '0'
184 )
185 ),
186 'cn_uno_member' => array(
187 'label' => 'LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_uno_member',
188 'exclude' => '0',
189 'config' => array(
190 'type' => 'check',
191 'default' => '0'
192 )
193 ),
194 'cn_address_format' => array(
195 'label' => 'LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_address_format',
196 'exclude' => '0',
197 'config' => array(
198 'type' => 'select',
199 'items' => array(
200 array('','0'),
201 array('LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_address_format_1','1'),
202 array('LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_address_format_2','2'),
203 array('LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_address_format_3','3'),
204 array('LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_address_format_4','4'),
205 array('LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_address_format_5','5'),
206 array('LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_address_format_6','6'),
207 array('LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_address_format_7','7'),
208 array('LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_address_format_8','8'),
209 array('LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_address_format_9','9'),
210 ),
211 'default' => '0'
212 )
213 ),
214 'cn_zone_flag' => array(
215 'label' => 'LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_zone_flag',
216 'exclude' => '0',
217 'config' => array(
218 'type' => 'check',
219 'default' => '0'
220 )
221 ),
222 'cn_short_local' => array(
223 'label' => 'LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_short_local',
224 'exclude' => '0',
225 'config' => array(
226 'type' => 'input',
227 'size' => '25',
228 'max' => '50',
229 'eval' => 'trim',
230 'default' => '',
231 '_is_string' => '1'
232 )
233 ),
234 'cn_short_en' => array(
235 'label' => 'LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_short_en',
236 'exclude' => '0',
237 'config' => array(
238 'type' => 'input',
239 'size' => '25',
240 'max' => '50',
241 'eval' => 'trim',
242 'default' => '',
243 '_is_string' => '1'
244 )
245 ),
246 'cn_country_zones' => array(
247 'label' => 'LLL:EXT:static_info_tables/Resources/Private/Language/locallang_db.xlf:static_countries_item.cn_country_zones',
248 'exclude' => '0',
249 'config' => array(
250 'type' => 'inline',
251 'foreign_table' => 'static_country_zones',
252 'foreign_field' => 'zn_country_uid',
253 'foreign_table_field' => 'zn_country_table',
254 'foreign_default_sortby' => 'zn_name_local',
255 'maxitems' => '200',
256 'appearance' => array(
257 'expandSingle' => 1,
258 'newRecordLinkAddTitle' => 1
259 )
260 )
261 )
262 ),
263 'types' => array(
264 '1' => array(
265 'showitem' => 'cn_short_local,cn_official_name_local,cn_official_name_en,--palette--;;1;;,--palette--;;5;;,--palette--;;2;;,--palette--;;3;;,--palette--;;6;;,--palette--;;4;;,cn_short_en,cn_country_zones'
266 )
267 ),
268 'palettes' => array(
269 '1' => array(
270 'showitem' => 'cn_iso_nr,cn_iso_2,cn_iso_3', 'canNotCollapse' => '1'
271 ),
272 '2' => array(
273 'showitem' => 'cn_currency_uid,cn_currency_iso_nr,cn_currency_iso_3', 'canNotCollapse' => '1'
274 ),
275 '3' => array(
276 'showitem' => 'cn_capital,cn_uno_member,cn_eu_member', 'canNotCollapse' => '1'
277 ),
278 '4' => array(
279 'showitem' => 'cn_address_format,cn_zone_flag', 'canNotCollapse' => '1'
280 ),
281 '5' => array(
282 'showitem' => 'cn_parent_territory_uid,cn_parent_tr_iso_nr', 'canNotCollapse' => '1'
283 ),
284 '6' => array(
285 'showitem' => 'cn_phone,cn_tldomain', 'canNotCollapse' => '1'
286 ),
287 )
288 );