Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions Classes/Hooks/DatamapDataHandlerHook.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,9 @@ public function processDatamap_beforeStart(DataHandler $dataHandler): void
}

$page = BackendUtility::getRecord('pages', abs($pageId));
$listType = $incomingFieldArray['list_type'] ?? '';

if (!$this->isAllowedTargetPage($incomingFieldArray['list_type'], $page['doktype'])) {
if (!$this->isAllowedTargetPage($listType, $page['doktype'])) {
unset($dataHandler->datamap['tt_content'][$id]);
$dataHandler->log(
'tt_content',
Expand Down Expand Up @@ -92,7 +93,7 @@ protected function isAllowedTargetPage($listType, $doktype)
if (($doktype == 186) && ($listType === 'cartevents_singleevent')) {
return true;
}
if (($doktype != 186) && ($listType === 'cartevents_events' || $listType === 'cartevents_eventdates' || $listType === 'cartevents_teaserevents')) {
if (($doktype != 186) && ($listType === 'cartevents_listevents' || $listType === 'cartevents_showevent' || $listType === 'cartevents_teaserevents' || $listType === 'cartevents_eventdates')) {
return true;
}

Expand Down
24 changes: 12 additions & 12 deletions Configuration/FlexForms/ListEventsPlugin.xml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<renderType>selectSingle</renderType>
<itemsProcFunc>Extcode\Cart\Hooks\ItemsProcFunc->user_templateLayout</itemsProcFunc>
<extKey>cart_events</extKey>
<pluginName>Events</pluginName>
<pluginName>ListEvents</pluginName>
</config>
</settings.templateLayout>

Expand All @@ -24,25 +24,25 @@
<type>select</type>
<renderType>selectSingle</renderType>
<items>
<numIndex index="0" type="array">
<numIndex index="0"></numIndex>
<numIndex index="1"></numIndex>
<numIndex index="0">
<label></label>
<value></value>
</numIndex>
<numIndex index="1">
<numIndex index="0">LLL:EXT:cart_events/Resources/Private/Language/locallang_be.xlf:tx_cartevents.plugin.events.action.event.list.orderBy.tstamp</numIndex>
<numIndex index="1">tstamp</numIndex>
<label>LLL:EXT:cart_events/Resources/Private/Language/locallang_be.xlf:tx_cartevents.plugin.events.action.event.list.orderBy.tstamp</label>
<value>tstamp</value>
</numIndex>
<numIndex index="2">
<numIndex index="0">LLL:EXT:cart_events/Resources/Private/Language/locallang_be.xlf:tx_cartevents.plugin.events.action.event.list.orderBy.sorting</numIndex>
<numIndex index="1">sorting</numIndex>
<label>LLL:EXT:cart_events/Resources/Private/Language/locallang_be.xlf:tx_cartevents.plugin.events.action.event.list.orderBy.sorting</label>
<value>sorting</value>
</numIndex>
<numIndex index="3">
<numIndex index="0">LLL:EXT:cart_events/Resources/Private/Language/locallang_be.xlf:tx_cartevents.plugin.events.action.event.list.orderBy.crdate</numIndex>
<numIndex index="1">crdate</numIndex>
<label>LLL:EXT:cart_events/Resources/Private/Language/locallang_be.xlf:tx_cartevents.plugin.events.action.event.list.orderBy.crdate</label>
<value>crdate</value>
</numIndex>
<numIndex index="4">
<numIndex index="0">LLL:EXT:cart_events/Resources/Private/Language/locallang_be.xlf:tx_cartevents.plugin.events.action.event.list.orderBy.title</numIndex>
<numIndex index="1">title</numIndex>
<label>LLL:EXT:cart_events/Resources/Private/Language/locallang_be.xlf:tx_cartevents.plugin.events.action.event.list.orderBy.title</label>
<value>title</value>
</numIndex>
</items>
</config>
Expand Down
2 changes: 1 addition & 1 deletion Resources/Private/Language/Overrides/cart/de.locallang.xlf
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<xliff version="1.0">
<file source-language="en" traget-language="de" datatype="plaintext" original="messages" date="2019-04-10T10:45:00Z" product-name="cart_events">
<file source-language="en" target-language="de" datatype="plaintext" original="messages" date="2019-04-10T10:45:00Z" product-name="cart_events">
<header/>
<body>

Expand Down