From f241fcba9b26425990bbd27844178fe4fe76727d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bjo=CC=88rn=20Fromme?= Date: Fri, 11 Oct 2019 22:08:31 +0200 Subject: [PATCH 1/2] Implement teaser for booking links --- .../Domain/Repository/ProductRepository.php | 1 + .../Classes/Service/DateImportService.php | 3 ++- .../Classes/Service/ProductDataService.php | 1 + .../typo3conf/ext/ep_products/ext_tables.sql | 1 + .../Mod/Wizards/NewContentElement.tsconfig | 9 ++++++- .../Configuration/PageTS/TCEFORM.tsconfig | 8 +++++++ .../Overrides/tt_content_element_teaser.php | 24 +++++++++++++++++++ .../ContentElements/teaser.typoscript | 2 ++ .../Private/Partials/Product/Teaser.html | 11 +++++---- .../Private/Partials/Product/TeaserWide.html | 13 ++++++---- .../FluidStyledContent/TeaserBookingLink.html | 24 +++++++++++++++++++ 11 files changed, 85 insertions(+), 12 deletions(-) create mode 100644 public/typo3conf/ext/ep_theme/Resources/Private/Templates/FluidStyledContent/TeaserBookingLink.html diff --git a/public/typo3conf/ext/ep_products/Classes/Domain/Repository/ProductRepository.php b/public/typo3conf/ext/ep_products/Classes/Domain/Repository/ProductRepository.php index 17d14afa..6ecc3ca8 100644 --- a/public/typo3conf/ext/ep_products/Classes/Domain/Repository/ProductRepository.php +++ b/public/typo3conf/ext/ep_products/Classes/Domain/Repository/ProductRepository.php @@ -146,6 +146,7 @@ class ProductRepository extends AbstractRepository ->select( 'product as productUid', 'product_name as productName', 'product_detail_page as productDetailPage', 'product_feature as productFeature', 'product_teaser as productTeaser', 'product_fact as productFact', + 'product_slug as productSlug', 'hotel as hotelUid', 'hotel_fact as hotelFact', 'hotel_name as hotelName', 'hotel_category as hotelCategory', 'region_fact as regionFact', 'region_name as regionName', 'region_feature as regionFeature', diff --git a/public/typo3conf/ext/ep_products/Classes/Service/DateImportService.php b/public/typo3conf/ext/ep_products/Classes/Service/DateImportService.php index f0942248..2cec6f07 100644 --- a/public/typo3conf/ext/ep_products/Classes/Service/DateImportService.php +++ b/public/typo3conf/ext/ep_products/Classes/Service/DateImportService.php @@ -235,7 +235,7 @@ class DateImportService implements SingletonInterface SELECT p.uid uid, p.daytrip daytrip, p.important important, p.name product_name, p.searchable product_searchable, p.detail_page product_detail_page, p.keywords product_keywords, p.teaser product_teaser, p.feature product_feature, p.subline product_subline, p.country country, - p.region region, p.city city, + p.region region, p.city city, p.path_segment slug, cnt.name country_name, cnt.code country_code, cnt.keywords country_keywords, r.name region_name, r.keywords region_keywords, r.feature region_feature, c.name city_name, c.keywords city_keywords, p.concept concept, con.name concept_name, con.code concept_code, con.sorting concept_sorting @@ -342,6 +342,7 @@ class DateImportService implements SingletonInterface 'product_feature' => $product['product_feature'], 'product_teaser' => $product['product_teaser'], 'product_subline' => $product['product_subline'], + 'product_slug' => $product['slug'], 'country' => $product['country'], 'country_name' => $product['country_name'], 'country_code' => $product['country_code'], diff --git a/public/typo3conf/ext/ep_products/Classes/Service/ProductDataService.php b/public/typo3conf/ext/ep_products/Classes/Service/ProductDataService.php index b933f7dc..83c6da30 100644 --- a/public/typo3conf/ext/ep_products/Classes/Service/ProductDataService.php +++ b/public/typo3conf/ext/ep_products/Classes/Service/ProductDataService.php @@ -204,6 +204,7 @@ class ProductDataService implements SingletonInterface 'name' => $teaserData['productName'], 'subline' => $teaserData['productSubline'], 'detailPage' => $teaserData['productDetailPage'], + 'slug' => $teaserData['productSlug'], 'fact' => $teaserData['productFact'], 'feature' => $teaserData['productFeature'], 'teaser' => $teaserData['productTeaser'], diff --git a/public/typo3conf/ext/ep_products/ext_tables.sql b/public/typo3conf/ext/ep_products/ext_tables.sql index d29aaf2b..bcb2d028 100644 --- a/public/typo3conf/ext/ep_products/ext_tables.sql +++ b/public/typo3conf/ext/ep_products/ext_tables.sql @@ -128,6 +128,7 @@ CREATE TABLE tx_epproducts_domain_model_date product_keywords text NOT NULL, product_teaser text NOT NULL, product_feature varchar(255) DEFAULT '' NOT NULL, + product_slug varchar(255) DEFAULT '' NOT NULL, concept int(11) unsigned DEFAULT '0', concept_name varchar(255) DEFAULT '' NOT NULL, concept_code varchar(32) DEFAULT '' NOT NULL, diff --git a/public/typo3conf/ext/ep_theme/Configuration/PageTS/Mod/Wizards/NewContentElement.tsconfig b/public/typo3conf/ext/ep_theme/Configuration/PageTS/Mod/Wizards/NewContentElement.tsconfig index 22b30da5..d9d8f31c 100644 --- a/public/typo3conf/ext/ep_theme/Configuration/PageTS/Mod/Wizards/NewContentElement.tsconfig +++ b/public/typo3conf/ext/ep_theme/Configuration/PageTS/Mod/Wizards/NewContentElement.tsconfig @@ -49,8 +49,15 @@ mod { description = Teaser für ein auswählbares Produkt tt_content_defValues.CType = teaser_product } + teaser_booking_link { + iconIdentifier = content-ep_theme-ce + title = Teaser Buchungslink + description = Teaser für ein auswählbares Produkt (Buchungslink) + tt_content_defValues.CType = teaser_booking_link + } } - show := addToList(teaser, teaser_country, teaser_region, teaser_city, teaser_hotel, teaser_concept, teaser_product) + show := addToList(teaser, teaser_country, teaser_region, teaser_city, teaser_hotel, teaser_concept) + show := addToList(teaser_product, teaser_booking_link) } disturber { header = Störer diff --git a/public/typo3conf/ext/ep_theme/Configuration/PageTS/TCEFORM.tsconfig b/public/typo3conf/ext/ep_theme/Configuration/PageTS/TCEFORM.tsconfig index 48dfd87b..cc8ceed2 100644 --- a/public/typo3conf/ext/ep_theme/Configuration/PageTS/TCEFORM.tsconfig +++ b/public/typo3conf/ext/ep_theme/Configuration/PageTS/TCEFORM.tsconfig @@ -82,6 +82,14 @@ TCEFORM { } } + layout.types.teaser_booking_link { + removeItems = 0,2 + altLabels { + 1 = einspaltig + 3 = mehrspaltig/quer + } + } + layout.types.ytvideo { removeItems = 2,3 altLabels { diff --git a/public/typo3conf/ext/ep_theme/Configuration/TCA/Overrides/tt_content_element_teaser.php b/public/typo3conf/ext/ep_theme/Configuration/TCA/Overrides/tt_content_element_teaser.php index 090d0cfb..1fec92ce 100644 --- a/public/typo3conf/ext/ep_theme/Configuration/TCA/Overrides/tt_content_element_teaser.php +++ b/public/typo3conf/ext/ep_theme/Configuration/TCA/Overrides/tt_content_element_teaser.php @@ -89,6 +89,18 @@ call_user_func(function() { 'after' ); + \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addTcaSelectItem( + 'tt_content', + 'CType', + [ + 'Teaser Buchungslink', + 'teaser_booking_link', + 'content-image' + ], + 'teaser_concept', + 'after' + ); + $GLOBALS['TCA']['tt_content']['types']['teaser'] = [ 'showitem' => ' --palette--;' . $frontendLanguageFilePrefix . 'palette.general;general, @@ -229,4 +241,16 @@ call_user_func(function() { ', ]; + $GLOBALS['TCA']['tt_content']['types']['teaser_booking_link'] = [ + 'showitem' => ' + --palette--;' . $frontendLanguageFilePrefix . 'palette.general;general, + --palette--;Kontext, tx_eptheme_context_product, + --div--;' . $frontendLanguageFilePrefix . 'tabs.appearance, + layout;' . $frontendLanguageFilePrefix . 'layout_formlabel, + --div--;' . $frontendLanguageFilePrefix . 'tabs.access, + hidden;' . $frontendLanguageFilePrefix . 'field.default.hidden, + --div--;' . $frontendLanguageFilePrefix . 'tabs.extended + ', + ]; + }); diff --git a/public/typo3conf/ext/ep_theme/Configuration/TypoScript/ContentElements/teaser.typoscript b/public/typo3conf/ext/ep_theme/Configuration/TypoScript/ContentElements/teaser.typoscript index ab084bbd..c787fcf4 100644 --- a/public/typo3conf/ext/ep_theme/Configuration/TypoScript/ContentElements/teaser.typoscript +++ b/public/typo3conf/ext/ep_theme/Configuration/TypoScript/ContentElements/teaser.typoscript @@ -27,3 +27,5 @@ tt_content.teaser_concept =< tt_content.teaser_country tt_content.teaser_concept.templateName = TeaserConcept tt_content.teaser_product =< tt_content.teaser_country tt_content.teaser_product.templateName = TeaserProduct +tt_content.teaser_booking_link =< tt_content.teaser_product +tt_content.teaser_booking_link.templateName = TeaserBookingLink diff --git a/public/typo3conf/ext/ep_theme/Resources/Private/Partials/Product/Teaser.html b/public/typo3conf/ext/ep_theme/Resources/Private/Partials/Product/Teaser.html index 7e310573..5f4b0291 100644 --- a/public/typo3conf/ext/ep_theme/Resources/Private/Partials/Product/Teaser.html +++ b/public/typo3conf/ext/ep_theme/Resources/Private/Partials/Product/Teaser.html @@ -21,12 +21,13 @@ - + + + + + - + diff --git a/public/typo3conf/ext/ep_theme/Resources/Private/Partials/Product/TeaserWide.html b/public/typo3conf/ext/ep_theme/Resources/Private/Partials/Product/TeaserWide.html index e96a28c0..6a1893a6 100644 --- a/public/typo3conf/ext/ep_theme/Resources/Private/Partials/Product/TeaserWide.html +++ b/public/typo3conf/ext/ep_theme/Resources/Private/Partials/Product/TeaserWide.html @@ -7,10 +7,13 @@ - + - + + + + @@ -22,7 +25,7 @@ {teaser.country.name} - + @@ -80,7 +83,7 @@ {f:if(condition: '{teaser.dates -> f:count()} > 1', then: 'Zeitraum', else: 'Termin')} {ep:dateRange(dateFrom: teaser.minDateStart, dateTo: teaser.maxDateEnd, includeLabel: 0)} - + {teaser.dates -> f:count()} Termin{f:if(condition: '{teaser.dates -> f:count()} > 1', then: 'e')} @@ -91,7 +94,7 @@ diff --git a/public/typo3conf/ext/ep_theme/Resources/Private/Templates/FluidStyledContent/TeaserBookingLink.html b/public/typo3conf/ext/ep_theme/Resources/Private/Templates/FluidStyledContent/TeaserBookingLink.html new file mode 100644 index 00000000..bbbdc69c --- /dev/null +++ b/public/typo3conf/ext/ep_theme/Resources/Private/Templates/FluidStyledContent/TeaserBookingLink.html @@ -0,0 +1,24 @@ + + + + + + + + + {f:variable(name: 'partial', value: 'Product/TeaserWide')} + + + {f:variable(name: 'partial', value: 'Product/TeaserWide')} + + + {f:variable(name: 'partial', value: 'Product/Teaser')} + + + + + + + From ed27375acdba96977fa5b946eab9831f3ad6d035 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bjo=CC=88rn=20Fromme?= Date: Fri, 11 Oct 2019 22:12:50 +0200 Subject: [PATCH 2/2] Update project dependencies --- composer.lock | 94 +++++++++++++++++++++++++-------------------------- 1 file changed, 47 insertions(+), 47 deletions(-) diff --git a/composer.lock b/composer.lock index d5892e8c..cf1f2fc7 100644 --- a/composer.lock +++ b/composer.lock @@ -1173,9 +1173,9 @@ "authors": [ { "name": "Helmut Hummel", - "role": "Developer", "email": "info@helhum.io", - "homepage": "http://helhum.io" + "homepage": "http://helhum.io", + "role": "Developer" } ], "description": "A reliable and powerful command line interface for TYPO3 CMS", @@ -3341,8 +3341,8 @@ "authors": [ { "name": "TYPO3 Core Team", - "role": "Developer", - "email": "typo3cms@typo3.org" + "email": "typo3cms@typo3.org", + "role": "Developer" } ], "description": "The TYPO3 admin panel provides a panel with additional functionality in the frontend (Debugging, Caching, Preview...)", @@ -3406,8 +3406,8 @@ "authors": [ { "name": "TYPO3 Core Team", - "role": "Developer", - "email": "typo3cms@typo3.org" + "email": "typo3cms@typo3.org", + "role": "Developer" } ], "description": "Classes for the TYPO3 backend.", @@ -3510,8 +3510,8 @@ "authors": [ { "name": "TYPO3 Core Team", - "role": "Developer", - "email": "typo3cms@typo3.org" + "email": "typo3cms@typo3.org", + "role": "Developer" } ], "description": "Backend user administration and overview. Allows you to compare the settings of users and verify their permissions and see who is online.", @@ -3725,8 +3725,8 @@ "authors": [ { "name": "TYPO3 Core Team", - "role": "Developer", - "email": "typo3cms@typo3.org" + "email": "typo3cms@typo3.org", + "role": "Developer" } ], "description": "The core library of TYPO3.", @@ -3841,8 +3841,8 @@ "authors": [ { "name": "TYPO3 Core Team", - "role": "Developer", - "email": "typo3cms@typo3.org" + "email": "typo3cms@typo3.org", + "role": "Developer" } ], "description": "TYPO3 Extension Manager", @@ -3947,8 +3947,8 @@ "authors": [ { "name": "TYPO3 Core Team", - "role": "Developer", - "email": "typo3cms@typo3.org" + "email": "typo3cms@typo3.org", + "role": "Developer" } ], "description": "Listing of files in the directory", @@ -4052,8 +4052,8 @@ "authors": [ { "name": "TYPO3 Core Team", - "role": "Developer", - "email": "typo3cms@typo3.org" + "email": "typo3cms@typo3.org", + "role": "Developer" } ], "description": "Fluid is a next-generation templating engine which makes the life of extension authors a lot easier!", @@ -4221,8 +4221,8 @@ "authors": [ { "name": "TYPO3 Core Team", - "role": "Developer", - "email": "typo3cms@typo3.org" + "email": "typo3cms@typo3.org", + "role": "Developer" } ], "description": "Classes for the frontend of TYPO3.", @@ -4280,8 +4280,8 @@ "authors": [ { "name": "TYPO3 Core Team", - "role": "Developer", - "email": "typo3cms@typo3.org" + "email": "typo3cms@typo3.org", + "role": "Developer" } ], "description": "Shows various infos", @@ -4338,8 +4338,8 @@ "authors": [ { "name": "TYPO3 Core Team", - "role": "Developer", - "email": "typo3cms@typo3.org" + "email": "typo3cms@typo3.org", + "role": "Developer" } ], "description": "The Install Tool mounted as the module Tools>Install in TYPO3.", @@ -4395,8 +4395,8 @@ "authors": [ { "name": "TYPO3 Core Team", - "role": "Developer", - "email": "typo3cms@typo3.org" + "email": "typo3cms@typo3.org", + "role": "Developer" } ], "description": "Enables the 'Config' and 'DB Check' modules for technical analysis of the system. This includes raw database search, checking relations, counting pages and records etc.", @@ -4454,8 +4454,8 @@ "authors": [ { "name": "TYPO3 Core Team", - "role": "Developer", - "email": "typo3cms@typo3.org" + "email": "typo3cms@typo3.org", + "role": "Developer" } ], "description": "List of database-records", @@ -4506,8 +4506,8 @@ "authors": [ { "name": "TYPO3 Core Team", - "role": "Developer", - "email": "typo3cms@typo3.org" + "email": "typo3cms@typo3.org", + "role": "Developer" } ], "description": "The recycler offers the possibility to restore deleted records or remove them from the database permanently. These actions can be applied to a single record, multiple records, and recursively to child records (ex. restoring a page can restore all content elements on that page). Filtering by page and by table provides a quick overview of deleted records before taking action on them.", @@ -4560,8 +4560,8 @@ "authors": [ { "name": "TYPO3 Core Team", - "role": "Developer", - "email": "typo3cms@typo3.org" + "email": "typo3cms@typo3.org", + "role": "Developer" } ], "description": "Custom redirects in TYPO3.", @@ -4675,8 +4675,8 @@ "authors": [ { "name": "TYPO3 Core Team", - "role": "Developer", - "email": "typo3cms@typo3.org" + "email": "typo3cms@typo3.org", + "role": "Developer" } ], "description": "Integration of CKEditor as Rich Text Editor.", @@ -4724,8 +4724,8 @@ "authors": [ { "name": "TYPO3 Core Team", - "role": "Developer", - "email": "typo3cms@typo3.org" + "email": "typo3cms@typo3.org", + "role": "Developer" } ], "description": "The TYPO3 Scheduler let's you register tasks to happen at a specific time", @@ -4778,8 +4778,8 @@ "authors": [ { "name": "TYPO3 Core Team", - "role": "Developer", - "email": "typo3cms@typo3.org" + "email": "typo3cms@typo3.org", + "role": "Developer" } ], "description": "SEO features for TYPO3.", @@ -4887,8 +4887,8 @@ "authors": [ { "name": "TYPO3 Core Team", - "role": "Developer", - "email": "typo3cms@typo3.org" + "email": "typo3cms@typo3.org", + "role": "Developer" } ], "description": "JavaScript-driven editor with syntax highlighting and codecompletion. Based on CodeMirror.", @@ -4988,8 +4988,8 @@ "authors": [ { "name": "TYPO3 Core Team", - "role": "Developer", - "email": "typo3cms@typo3.org" + "email": "typo3cms@typo3.org", + "role": "Developer" } ], "description": "Framework for management of TypoScript template records for the CMS frontend.", @@ -5040,8 +5040,8 @@ "authors": [ { "name": "TYPO3 Core Team", - "role": "Developer", - "email": "typo3cms@typo3.org" + "email": "typo3cms@typo3.org", + "role": "Developer" } ], "description": "Shows the frontend webpage inside the backend frameset.", @@ -5167,16 +5167,16 @@ }, { "name": "yoast-seo-for-typo3/yoast_seo", - "version": "v5.1.0", + "version": "v5.1.1", "source": { "type": "git", "url": "https://github.com/Yoast/Yoast-SEO-for-TYPO3.git", - "reference": "76b5bc54a215dc7d8957677ca24c9813f6dc787a" + "reference": "3f7dda6c97cb5438cc3a39660f2ee032b557547c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Yoast/Yoast-SEO-for-TYPO3/zipball/76b5bc54a215dc7d8957677ca24c9813f6dc787a", - "reference": "76b5bc54a215dc7d8957677ca24c9813f6dc787a", + "url": "https://api.github.com/repos/Yoast/Yoast-SEO-for-TYPO3/zipball/3f7dda6c97cb5438cc3a39660f2ee032b557547c", + "reference": "3f7dda6c97cb5438cc3a39660f2ee032b557547c", "shasum": "" }, "require": { @@ -5232,7 +5232,7 @@ "seo", "yoast" ], - "time": "2019-09-20T14:23:25+00:00" + "time": "2019-10-10T17:32:36+00:00" }, { "name": "yohang/calendr",