-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathext_tables.php
37 lines (34 loc) · 1.12 KB
/
ext_tables.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
<?php
if (!defined('TYPO3_MODE')) {
die ('Access denied.');
}
/**
* Add new fields to fe_users table
*/
$GLOBALS['TCA']['fe_users']['ctrl']['type'] = 'tx_extbase_type';
$tmpFeUsersColumns = [
'comment' => [
'exclude' => 1,
'label' => 'LLL:EXT:femanagerextendedcustom/Resources/Private/Language/locallang_db.xlf:' .
'tx_femanagerextendedcustom_domain_model_user.comment',
'config' => [
'type' => 'text',
'rows' => 15,
'cols' => 40
],
],
'tx_extbase_type' => [
'config' => [
'type' => 'input',
'default' => '0'
]
]
];
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addTCAcolumns('fe_users', $tmpFeUsersColumns, true);
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addToAllTCAtypes('fe_users', 'comment');
/**
* Add page TSConfig for the two new fields
*/
$tsConfig = 'tx_femanager.flexForm.new.addFieldOptions.comment = Comment' . PHP_EOL;
$tsConfig .= 'tx_femanager.flexForm.edit < tx_femanager.flexForm.new';
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addPageTSConfig($tsConfig);