a4db09ccb05dd73f8b35ae4a37b0dc6ac538c4b7
[TYPO3CMS/Extensions/contagged.git] / ext_tables.php
1 <?php
2 if (!defined('TYPO3_MODE')) {
3 die ('Access denied.');
4 }
5
6 t3lib_extMgm::allowTableOnStandardPages('tx_contagged_terms');
7 t3lib_extMgm::addToInsertRecords('tx_contagged_terms');
8
9 // add contagged to the "insert plugin" content element
10 t3lib_extMgm::addPlugin(array('LLL:EXT:contagged/locallang_db.php:tx_contagged_terms.plugin', $_EXTKEY . '_pi1'), 'list_type');
11
12 // initialize static extension templates
13 t3lib_extMgm::addStaticFile($_EXTKEY, 'static/', 'Content parser');
14 t3lib_extMgm::addStaticFile($_EXTKEY, 'static/examples/', 'Experimental Setup');
15
16 $TCA["tx_contagged_terms"] = array(
17 "ctrl" => array(
18 'title' => 'LLL:EXT:contagged/locallang_db.xml:tx_contagged_terms',
19 'label' => 'term_replace',
20 'label_alt' => 'term_main, term_alt',
21 'label_alt_force' => TRUE,
22 'tstamp' => 'tstamp',
23 'crdate' => 'crdate',
24 'cruser_id' => 'cruser_id',
25 'versioningWS' => TRUE,
26 'origUid' => 't3_origuid',
27 'languageField' => 'sys_language_uid',
28 'transOrigPointerField' => 'l18n_parent',
29 'transOrigDiffSourceField' => 'l18n_diffsource',
30 'sortby' => 'sorting',
31 'delete' => 'deleted',
32 'enablecolumns' => array(
33 'disabled' => 'hidden',
34 'starttime' => 'starttime',
35 'endtime' => 'endtime',
36 'fe_group' => 'fe_group',
37 ),
38 'useColumnsForDefaultValues' => 'term_type',
39 'dynamicConfigFile' => t3lib_extMgm::extPath($_EXTKEY) . 'tca.php',
40 'iconfile' => t3lib_extMgm::extRelPath($_EXTKEY) . 'icon_tx_contagged_terms.gif',
41 ),
42 "feInterface" => array(
43 "fe_admin_fieldList" => "sys_language_uid, l18n_parent, l18n_diffsource, hidden, starttime, endtime, fe_group, term_main, term_alt, term_type, term_lang, term_replace, desc_short, desc_long, image, dam_images, imagecaption, imagealt, imagetitle, related, link, exclude",
44 )
45 );
46
47 // Add a field "exclude this page from parsing" to the table "pages" and "tt_content"
48 $tempColumns = Array(
49 "tx_contagged_dont_parse" => Array(
50 "exclude" => 1,
51 "label" => "LLL:EXT:contagged/locallang_db.xml:pages.tx_contagged_dont_parse",
52 "config" => Array(
53 "type" => "check",
54 )
55 ),
56 );
57
58 t3lib_div::loadTCA("pages");
59 t3lib_extMgm::addTCAcolumns("pages", $tempColumns, 1);
60 t3lib_extMgm::addToAllTCAtypes("pages", "tx_contagged_dont_parse;;;;1-1-1");
61
62 t3lib_div::loadTCA("tt_content");
63 t3lib_extMgm::addTCAcolumns("tt_content", $tempColumns, 1);
64 t3lib_extMgm::addToAllTCAtypes("tt_content", "tx_contagged_dont_parse;;;;1-1-1");
65
66 ?>