Implement plugin for booking link page rendering
This commit is contained in:
@@ -120,6 +120,24 @@ routeEnhancers:
|
||||
type: PersistedAliasMapper
|
||||
tableName: tx_epproducts_domain_model_hotel
|
||||
routeFieldName: uid
|
||||
BookingLinkPlugin:
|
||||
type: Extbase
|
||||
extension: EpProducts
|
||||
plugin: booking_link
|
||||
limitToPages:
|
||||
- 1787
|
||||
routes:
|
||||
-
|
||||
routePath: '/{product}'
|
||||
_controller: 'Product::detail'
|
||||
_arguments:
|
||||
product: product
|
||||
defaultController: 'Product::detail'
|
||||
aspects:
|
||||
product:
|
||||
type: PersistedAliasMapper
|
||||
tableName: tx_epproducts_domain_model_product
|
||||
routeFieldName: path_segment
|
||||
SearchResultPlugin:
|
||||
type: Extbase
|
||||
extension: EpProducts
|
||||
|
||||
@@ -29,6 +29,12 @@ call_user_func(function () {
|
||||
'Produktdetails'
|
||||
);
|
||||
|
||||
\TYPO3\CMS\Extbase\Utility\ExtensionUtility::registerPlugin(
|
||||
'EP.EpProducts',
|
||||
'booking_link',
|
||||
'Buchungslink'
|
||||
);
|
||||
|
||||
\TYPO3\CMS\Extbase\Utility\ExtensionUtility::registerPlugin(
|
||||
'EP.EpProducts',
|
||||
'product_teasergroup',
|
||||
|
||||
+19
-3
@@ -28,7 +28,7 @@ return [
|
||||
concept_description, board_description, additional_services, programme_description, ski_pass_description,
|
||||
rating_average, rating_votes_count, teaser_images, header_images, images, concept, country, region, city,
|
||||
journey, facts, officetip, hotels, calendar_hotel, faqs,header_title,header_subtitle, alt_product, alt_label,
|
||||
video, banner, additional_regions, badge, daytrip, testimonials, external_link',
|
||||
video, banner, additional_regions, badge, daytrip, testimonials, external_link, path_segment',
|
||||
],
|
||||
'types' => [
|
||||
'1' => [
|
||||
@@ -45,7 +45,7 @@ return [
|
||||
'palettes' => [
|
||||
'destinations' => ['showitem' => 'country,region,city'],
|
||||
'top' => ['showitem' => 'searchable, bookable, daytrip, important, skipass_included, detail_page,
|
||||
external_link'],
|
||||
external_link, path_segment'],
|
||||
'name' => ['showitem' => 'name,code'],
|
||||
'alternative' => ['showitem' => 'alt_product, alt_label'],
|
||||
'header' => ['showitem' => 'headline,subline,--linebreak--,header_title,header_subtitle'],
|
||||
@@ -806,6 +806,22 @@ return [
|
||||
'type' => 'input',
|
||||
'eval' => 'trim',
|
||||
]
|
||||
]
|
||||
],
|
||||
'path_segment' => [
|
||||
'exclude' => 0,
|
||||
'label' => 'Buchungslink URL',
|
||||
'config' => [
|
||||
'type' => 'slug',
|
||||
'generatorOptions' => [
|
||||
'fields' => ['name'],
|
||||
'prefixParentPageSlug' => false,
|
||||
'replacements' => [
|
||||
'/' => '-',
|
||||
],
|
||||
],
|
||||
'fallbackCharacter' => '-',
|
||||
'eval' => 'uniqueInSite',
|
||||
],
|
||||
],
|
||||
],
|
||||
];
|
||||
|
||||
@@ -80,6 +80,17 @@ $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['scheduler']['tasks'][\EP\EpProducts\T
|
||||
]
|
||||
);
|
||||
|
||||
\TYPO3\CMS\Extbase\Utility\ExtensionUtility::configurePlugin(
|
||||
'EP.' . $_EXTKEY,
|
||||
'booking_link',
|
||||
[
|
||||
'Product' => 'detail,hotelList',
|
||||
],
|
||||
[
|
||||
'Product' => '',
|
||||
]
|
||||
);
|
||||
|
||||
\TYPO3\CMS\Extbase\Utility\ExtensionUtility::configurePlugin(
|
||||
'EP.' . $_EXTKEY,
|
||||
'product_teasergroup',
|
||||
|
||||
@@ -22,6 +22,7 @@ CREATE TABLE tx_epproducts_domain_model_product
|
||||
bus_pro_id int(11) unsigned NOT NULL default '0',
|
||||
detail_page varchar(255) DEFAULT '' NOT NULL,
|
||||
external_link varchar(255) DEFAULT '' NOT NULL,
|
||||
path_segment varchar(255) DEFAULT '' NOT NULL,
|
||||
description text NOT NULL,
|
||||
teaser text NOT NULL,
|
||||
teaser_long text NOT NULL,
|
||||
|
||||
@@ -63,6 +63,9 @@ class ContextProcessor implements DataProcessorInterface
|
||||
if ($regionUid > 0) {
|
||||
$processedData['context']['region'] = $this->getContextRecord($regionUid, 'tx_epproducts_domain_model_region');
|
||||
}
|
||||
if ($data['tx_eptheme_context_pacode']) {
|
||||
$processedData['context']['paCode'] = $data['tx_eptheme_context_pacode'];
|
||||
} else {
|
||||
$resellerData = $this->getResellerData();
|
||||
if ($resellerData) {
|
||||
$processedData['context']['paCode'] = $resellerData['paCode'];
|
||||
@@ -71,6 +74,7 @@ class ContextProcessor implements DataProcessorInterface
|
||||
} elseif ($cookieData = CookieUtility::getPaCookie()) {
|
||||
$processedData['context']['paCode'] = $cookieData;
|
||||
}
|
||||
}
|
||||
|
||||
return $processedData;
|
||||
}
|
||||
|
||||
@@ -5,6 +5,15 @@ defined('TYPO3_MODE') or die();
|
||||
call_user_func(function() {
|
||||
|
||||
$temporaryColumns = [
|
||||
'tx_eptheme_context_pacode' => [
|
||||
'exclude' => 0,
|
||||
'label' => 'PA Code für diese Seite',
|
||||
'config' => [
|
||||
'type' => 'input',
|
||||
'size' => 8,
|
||||
'eval' => 'trim',
|
||||
],
|
||||
],
|
||||
'tx_eptheme_context_country_code' => [
|
||||
'config' => [
|
||||
'type' => 'passthrough'
|
||||
@@ -101,7 +110,7 @@ call_user_func(function() {
|
||||
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addToAllTCAtypes(
|
||||
'pages',
|
||||
'--div--;Kontext,
|
||||
tx_eptheme_context_country,tx_eptheme_context_region,
|
||||
tx_eptheme_context_pacode,tx_eptheme_context_country,tx_eptheme_context_region,
|
||||
tx_eptheme_hide_searchbar,tx_eptheme_bodyclass,
|
||||
--div--;Slider,
|
||||
tx_eptheme_slides,
|
||||
|
||||
@@ -2,7 +2,8 @@
|
||||
#
|
||||
# Table structure for table 'tx_eptheme_domain_model_slider'
|
||||
#
|
||||
CREATE TABLE tx_eptheme_domain_model_slide (
|
||||
CREATE TABLE tx_eptheme_domain_model_slide
|
||||
(
|
||||
|
||||
uid int(11) NOT NULL auto_increment,
|
||||
pid int(11) DEFAULT '0' NOT NULL,
|
||||
@@ -47,7 +48,8 @@ CREATE TABLE tx_eptheme_domain_model_slide (
|
||||
#
|
||||
# Table structure for table 'tx_eptheme_domain_model_lineup'
|
||||
#
|
||||
CREATE TABLE tx_eptheme_domain_model_lineup (
|
||||
CREATE TABLE tx_eptheme_domain_model_lineup
|
||||
(
|
||||
|
||||
uid int(11) NOT NULL auto_increment,
|
||||
pid int(11) DEFAULT '0' NOT NULL,
|
||||
@@ -91,7 +93,9 @@ CREATE TABLE tx_eptheme_domain_model_lineup (
|
||||
|
||||
);
|
||||
|
||||
CREATE TABLE pages (
|
||||
CREATE TABLE pages
|
||||
(
|
||||
tx_eptheme_context_pacode char(8) DEFAULT '',
|
||||
tx_eptheme_context_country_code char(2) DEFAULT '',
|
||||
tx_eptheme_context_country int(11) unsigned DEFAULT '0',
|
||||
tx_eptheme_context_region int(11) unsigned DEFAULT '0',
|
||||
@@ -103,7 +107,8 @@ CREATE TABLE pages (
|
||||
tx_eptheme_badge int(11) unsigned DEFAULT '0'
|
||||
);
|
||||
|
||||
CREATE TABLE pages_language_overlay (
|
||||
CREATE TABLE pages_language_overlay
|
||||
(
|
||||
tx_eptheme_context_country_code char(2) DEFAULT '',
|
||||
tx_eptheme_context_country int(11) unsigned DEFAULT '0',
|
||||
tx_eptheme_context_region int(11) unsigned DEFAULT '0',
|
||||
@@ -115,7 +120,8 @@ CREATE TABLE pages_language_overlay (
|
||||
tx_eptheme_badge int(11) unsigned DEFAULT '0'
|
||||
);
|
||||
|
||||
CREATE TABLE tt_content (
|
||||
CREATE TABLE tt_content
|
||||
(
|
||||
tx_eptheme_context_country int(11) unsigned DEFAULT '0',
|
||||
tx_eptheme_context_region int(11) unsigned DEFAULT '0',
|
||||
tx_eptheme_context_city int(11) unsigned DEFAULT '0',
|
||||
@@ -129,7 +135,8 @@ CREATE TABLE tt_content (
|
||||
button varchar(255) DEFAULT '' NOT NULL
|
||||
);
|
||||
|
||||
CREATE TABLE tx_eptheme_domain_model_addresscheck (
|
||||
CREATE TABLE tx_eptheme_domain_model_addresscheck
|
||||
(
|
||||
uid int(11) NOT NULL auto_increment,
|
||||
pid int(11) DEFAULT '0' NOT NULL,
|
||||
tstamp int(11) DEFAULT '0' NOT NULL,
|
||||
|
||||
Reference in New Issue
Block a user