events/Configuration/TCA/tx_events_domain_model_event.php

479 lines
17 KiB
PHP
Raw Normal View History

<?php
2021-02-11 13:13:05 +01:00
$l10nPathGeneral = 'LLL:EXT:core/Resources/Private/Language/locallang_general.xlf';
$l10nPathLang = 'LLL:EXT:lang/locallang_core.xlf';
$l10nPathFE = 'LLL:EXT:frontend/Resources/Private/Language/locallang_ttc.xlf';
$l10nPath = 'LLL:EXT:events/Resources/Private/Language/locallang_csh_event.xlf';
2022-08-02 15:56:18 +02:00
$l10nLocationPath = 'LLL:EXT:events/Resources/Private/Language/locallang_csh_location.xlf';
2021-02-11 13:13:05 +01:00
return [
'ctrl' => [
2021-02-11 13:13:05 +01:00
'title' => $l10nPath . ':tx_events_domain_model_event',
'label' => 'title',
'tstamp' => 'tstamp',
'crdate' => 'crdate',
'cruser_id' => 'cruser_id',
'versioningWS' => true,
'languageField' => 'sys_language_uid',
'transOrigPointerField' => 'l10n_parent',
'transOrigDiffSourceField' => 'l10n_diffsource',
'delete' => 'deleted',
'enablecolumns' => [
'disabled' => 'hidden',
'starttime' => 'starttime',
'endtime' => 'endtime',
],
2021-02-15 09:58:51 +01:00
'searchFields' => 'title,subtitle,global_id,teaser',
2021-02-11 12:05:02 +01:00
'iconfile' => 'EXT:events/Resources/Public/Icons/tx_events_domain_model_event.svg'
],
'types' => [
2021-02-11 13:13:05 +01:00
'1' => [
'showitem' => '--palette--;' . $l10nPathFE . ':palette.general;general,
sys_language_uid,
l10n_parent,
l10n_diffsource,
hidden,
highlight,
title,
2021-02-15 09:58:51 +01:00
subtitle,
2021-02-11 13:13:05 +01:00
teaser,
slug,
ticket,
global_id,
--div--;' . $l10nPath . ':tx_events_domain_model_event.tabs.text,
details,
price_info,
--div--;' . $l10nPath . ':tx_events_domain_model_event.tabs.dates,
dates,
--div--;' . $l10nPath . ':tx_events_domain_model_event.tabs.location,
2022-08-02 15:56:18 +02:00
location,
2021-02-11 13:13:05 +01:00
--div--;' . $l10nPath . ':tx_events_domain_model_event.tabs.relations,
organizer,
region,
partner,
categories,
features,
references_events,
2021-02-11 13:13:05 +01:00
pages,
--div--;' . $l10nPath . ':tx_events_domain_model_event.tabs.media,
images,
--div--;' . $l10nPath . ':tx_events_domain_model_event.tabs.social,
2022-08-02 15:56:18 +02:00
web,
2021-02-11 13:13:05 +01:00
facebook,
youtube,
instagram,
--div--;' . $l10nPathFE . ':tabs.access,
starttime,
endtime'
],
],
2021-02-11 13:13:05 +01:00
'columns' => [
'sys_language_uid' => [
'exclude' => true,
2021-02-11 13:13:05 +01:00
'label' => $l10nPathGeneral . ':LGL.language',
'config' => [
'type' => 'select',
'renderType' => 'selectSingle',
'special' => 'languages',
'items' => [
[
2021-02-11 13:13:05 +01:00
$l10nPathGeneral . ':LGL.allLanguages',
-1,
'flags-multiple'
]
],
'default' => 0,
],
],
'l10n_parent' => [
'displayCond' => 'FIELD:sys_language_uid:>:0',
2021-02-11 13:13:05 +01:00
'label' => $l10nPathGeneral . ':LGL.l18n_parent',
'config' => [
'type' => 'select',
'renderType' => 'selectSingle',
'default' => 0,
'items' => [
['', 0],
],
'foreign_table' => 'tx_events_domain_model_event',
'foreign_table_where' => 'AND {#tx_events_domain_model_event}.{#pid}=###CURRENT_PID### AND {#tx_events_domain_model_event}.{#sys_language_uid} IN (-1,0)',
],
],
'l10n_diffsource' => [
'config' => [
'type' => 'passthrough',
],
],
't3ver_label' => [
2021-02-11 13:13:05 +01:00
'label' => $l10nPathGeneral . ':LGL.versionLabel',
'config' => [
'type' => 'input',
'size' => 30,
'max' => 255,
],
],
'hidden' => [
'exclude' => true,
2021-02-11 13:13:05 +01:00
'label' => $l10nPathGeneral . ':LGL.visible',
'config' => [
'type' => 'check',
'renderType' => 'checkboxToggle',
'items' => [
[
0 => '',
1 => '',
'invertStateDisplay' => true
]
],
],
],
'starttime' => [
'exclude' => true,
2021-02-11 13:13:05 +01:00
'label' => $l10nPathGeneral . ':LGL.starttime',
'config' => [
'type' => 'input',
'renderType' => 'inputDateTime',
'eval' => 'datetime,int',
'default' => 0,
'behaviour' => [
'allowLanguageSynchronization' => true
]
],
],
'endtime' => [
'exclude' => true,
2021-02-11 13:13:05 +01:00
'label' => $l10nPathGeneral . ':LGL.endtime',
'config' => [
'type' => 'input',
'renderType' => 'inputDateTime',
'eval' => 'datetime,int',
'default' => 0,
'range' => [
'upper' => mktime(0, 0, 0, 1, 1, 2038)
],
'behaviour' => [
'allowLanguageSynchronization' => true
]
],
],
'title' => [
'exclude' => true,
2021-02-11 13:13:05 +01:00
'label' => $l10nPath . ':tx_events_domain_model_event.title',
'config' => [
2021-03-08 13:45:31 +01:00
'type' => 'text',
'cols' => 40,
'rows' => 2,
'eval' => 'trim'
]
],
2021-02-15 09:58:51 +01:00
'subtitle' => [
'exclude' => true,
'label' => $l10nPath . ':tx_events_domain_model_event.subtitle',
'config' => [
2021-03-08 13:45:31 +01:00
'type' => 'text',
'cols' => 40,
'rows' => 2,
2021-02-15 09:58:51 +01:00
'eval' => 'trim'
]
],
'global_id' => [
'exclude' => true,
2021-02-11 13:13:05 +01:00
'label' => $l10nPath . ':tx_events_domain_model_event.global_id',
'config' => [
'type' => 'input',
'size' => 30,
'eval' => 'trim'
],
],
'slug' => [
'exclude' => true,
2021-02-11 13:13:05 +01:00
'label' => $l10nPath . ':tx_events_domain_model_event.slug',
'config' => [
'type' => 'slug',
'size' => 50,
'generatorOptions' => [
'fields' => ['title'],
'fieldSeparator' => '/',
'prefixParentPageSlug' => false,
],
'fallbackCharacter' => '-',
'eval' => 'uniqueInSite',
'default' => '',
],
],
'highlight' => [
'exclude' => true,
2021-02-11 13:13:05 +01:00
'label' => $l10nPath . ':tx_events_domain_model_event.highlight',
'config' => [
'type' => 'check',
'items' => [
'1' => [
2021-02-11 13:13:05 +01:00
'0' => $l10nPathLang . ':labels.enabled'
]
],
'default' => 0,
]
],
'teaser' => [
'exclude' => true,
2021-02-11 13:13:05 +01:00
'label' => $l10nPath . ':tx_events_domain_model_event.teaser',
'config' => [
'type' => 'text',
2021-02-11 13:13:05 +01:00
'cols' => 30,
'rows' => 5,
'eval' => 'trim'
]
],
'details' => [
'exclude' => true,
2021-02-11 13:13:05 +01:00
'label' => $l10nPath . ':tx_events_domain_model_event.details',
'config' => [
'type' => 'text',
'enableRichtext' => true,
'fieldControl' => [
'fullScreenRichtext' => [
'disabled' => false,
],
],
'cols' => 40,
'rows' => 15,
'eval' => 'trim',
],
],
'price_info' => [
'exclude' => true,
2021-02-11 13:13:05 +01:00
'label' => $l10nPath . ':tx_events_domain_model_event.price_info',
'config' => [
'type' => 'text',
'cols' => 40,
'rows' => 15,
'eval' => 'trim'
]
],
'web' => [
'exclude' => true,
2021-02-11 13:13:05 +01:00
'label' => $l10nPath . ':tx_events_domain_model_event.web',
'config' => [
'type' => 'input',
'size' => 30,
'eval' => 'trim'
],
],
2020-08-19 11:30:13 +02:00
'ticket' => [
'exclude' => true,
2021-02-11 13:13:05 +01:00
'label' => $l10nPath . ':tx_events_domain_model_event.ticket',
'config' => [
'type' => 'input',
2021-02-11 13:13:05 +01:00
'renderType' => 'inputLink',
'eval' => 'trim',
'max' => 1024,
'size' => 50,
'softref' => 'typolink',
],
],
2020-08-19 11:30:13 +02:00
'facebook' => [
'exclude' => true,
2021-02-11 13:13:05 +01:00
'label' => $l10nPath . ':tx_events_domain_model_event.facebook',
'config' => [
'type' => 'input',
'size' => 30,
'eval' => 'trim'
],
],
2020-08-19 11:30:13 +02:00
'youtube' => [
'exclude' => true,
2021-02-11 13:13:05 +01:00
'label' => $l10nPath . ':tx_events_domain_model_event.youtube',
'config' => [
'type' => 'input',
'size' => 30,
'eval' => 'trim'
],
],
2020-08-19 11:30:13 +02:00
'instagram' => [
'exclude' => true,
2021-02-11 13:13:05 +01:00
'label' => $l10nPath . ':tx_events_domain_model_event.instagram',
'config' => [
'type' => 'input',
'size' => 30,
'eval' => 'trim'
],
],
'images' => [
'exclude' => true,
2021-02-11 13:13:05 +01:00
'label' => $l10nPath . ':tx_events_domain_model_event.images',
'config' => \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getFileFieldTCAConfig(
'images',
[
'appearance' => [
2021-02-11 13:13:05 +01:00
'createNewRelationLinkTitle' => $l10nPathFE . ':images.addFileReference',
'showPossibleLocalizationRecords' => true,
'showRemovedLocalizationRecords' => true,
'showAllLocalizationLink' => true,
'showSynchronizationLink' => true,
],
'foreign_match_fields' => [
'fieldname' => 'images',
'tablenames' => 'tx_events_domain_model_event',
'table_local' => 'sys_file',
],
'foreign_types' => [
'0' => [
'showitem' => '
2021-02-11 13:13:05 +01:00
--palette--;' . $l10nPathFE . ':sys_file_reference.imageoverlayPalette;imageoverlayPalette,
--palette--;;filePalette'
],
\TYPO3\CMS\Core\Resource\File::FILETYPE_TEXT => [
'showitem' => '
2021-02-11 13:13:05 +01:00
--palette--;' . $l10nPathFE . ':sys_file_reference.imageoverlayPalette;imageoverlayPalette,
--palette--;;filePalette'
],
\TYPO3\CMS\Core\Resource\File::FILETYPE_IMAGE => [
'showitem' => '
2021-02-11 13:13:05 +01:00
--palette--;' . $l10nPathFE . ':sys_file_reference.imageoverlayPalette;imageoverlayPalette,
--palette--;;filePalette'
],
\TYPO3\CMS\Core\Resource\File::FILETYPE_AUDIO => [
'showitem' => '
2021-02-11 13:13:05 +01:00
--palette--;' . $l10nPathFE . ':sys_file_reference.imageoverlayPalette;imageoverlayPalette,
--palette--;;filePalette'
],
\TYPO3\CMS\Core\Resource\File::FILETYPE_VIDEO => [
'showitem' => '
2021-02-11 13:13:05 +01:00
--palette--;' . $l10nPathFE . ':sys_file_reference.imageoverlayPalette;imageoverlayPalette,
--palette--;;filePalette'
],
\TYPO3\CMS\Core\Resource\File::FILETYPE_APPLICATION => [
'showitem' => '
2021-02-11 13:13:05 +01:00
--palette--;' . $l10nPathFE . ':sys_file_reference.imageoverlayPalette;imageoverlayPalette,
--palette--;;filePalette'
]
],
2021-03-19 14:26:47 +01:00
'maxitems' => 8
],
$GLOBALS['TYPO3_CONF_VARS']['GFX']['imagefile_ext']
),
],
'pages' => [
'exclude' => true,
2021-02-11 13:13:05 +01:00
'label' => $l10nPath . ':tx_events_domain_model_event.pages',
'config' => [
'type' => 'group',
'internal_type' => 'db',
'allowed' => 'pages',
],
],
'categories' => [
'exclude' => true,
],
'features' => [
'exclude' => true,
],
'dates' => [
'exclude' => true,
2021-02-11 13:13:05 +01:00
'label' => $l10nPath . ':tx_events_domain_model_event.dates',
'config' => [
'type' => 'inline',
'foreign_table' => 'tx_events_domain_model_date',
'foreign_field' => 'event',
'maxitems' => 9999,
'appearance' => [
'collapseAll' => 1,
'useSortable' => 0,
'expandSingle' => 1,
'enabledControls' => array(
'info' => false,
'new' => true,
'dragdrop' => true,
'sort' => true,
'hide' => false,
2021-03-16 13:32:34 +01:00
'delete' => true,
'localize' => false,
),
'levelLinksPosition' => 'top',
'showPossibleLocalizationRecords' => false,
'showRemovedLocalizationRecords' => false,
'showSynchronizationLink' => false,
'showAllLocalizationLink' => false,
],
],
],
2022-08-02 15:56:18 +02:00
'location' => [
'exclude' => true,
'label' => $l10nPath . ':tx_events_domain_model_event.location',
'config' => [
'type' => 'select',
'renderType' => 'selectSingle',
'foreign_table' => 'tx_events_domain_model_location',
'default' => 0,
'minitems' => 0,
'maxitems' => 1,
],
],
'organizer' => [
'exclude' => true,
2021-02-11 13:13:05 +01:00
'label' => $l10nPath . ':tx_events_domain_model_event.organizer',
'config' => [
'type' => 'select',
'renderType' => 'selectSingle',
'foreign_table' => 'tx_events_domain_model_organizer',
2021-02-24 16:08:17 +01:00
'default' => 0,
'minitems' => 0,
'maxitems' => 1,
],
],
'region' => [
'exclude' => true,
2021-02-11 13:13:05 +01:00
'label' => $l10nPath . ':tx_events_domain_model_event.region',
'config' => [
'type' => 'select',
'renderType' => 'selectSingle',
'foreign_table' => 'tx_events_domain_model_region',
2021-02-24 16:08:17 +01:00
'default' => 0,
'minitems' => 0,
'maxitems' => 1,
],
],
'references_events' => [
'exclude' => true,
'label' => $l10nPath . ':tx_events_domain_model_event.references_events',
'config' => [
'type' => 'group',
'internal_type' => 'db',
'allowed' => 'tx_events_domain_model_event',
'suggestOptions' => [
'tx_events_domain_model_event' => [
'searchCondition' => 'tx_events_domain_model_event.sys_language_uid IN (0, -1)',
],
],
],
],
'partner' => [
'exclude' => true,
2021-02-11 13:13:05 +01:00
'label' => $l10nPath . ':tx_events_domain_model_event.partner',
'config' => [
'type' => 'group',
'internal_type' => 'db',
'allowed' => 'tx_events_domain_model_partner',
'fieldControl' => [
'addRecord' => [
'disabled' => false,
'pid' => '###CURRENT_PID###',
'table' => 'tx_events_domain_model_partner',
],
],
],
],
],
];