From bd51b37159367222a0d1c1c848e04f7facd413bf Mon Sep 17 00:00:00 2001 From: MaxBUhe Date: Mon, 20 Mar 2023 09:49:49 +0100 Subject: [PATCH 1/2] hot-fix: add missing view_item file; add metadata entry --- Application/views/blocks/view_item.tpl | 25 +++++++++++++++++++++++++ Application/views/ga4/add_to_cart.tpl | 3 ++- Application/views/ga4/view_item.tpl | 26 -------------------------- metadata.php | 7 +++++++ 4 files changed, 34 insertions(+), 27 deletions(-) create mode 100644 Application/views/blocks/view_item.tpl delete mode 100644 Application/views/ga4/view_item.tpl diff --git a/Application/views/blocks/view_item.tpl b/Application/views/blocks/view_item.tpl new file mode 100644 index 0000000..ac54467 --- /dev/null +++ b/Application/views/blocks/view_item.tpl @@ -0,0 +1,25 @@ +[{$smarty.block.parent}] +[{assign var="gtmProduct" value=$oView->getProduct()}] +[{assign var="gtmCategory" value=$gtmProduct->getCategory()}] +[{assign var="gtmManufacturer" value=$gtmProduct->getManufacturer()}] + + \ No newline at end of file diff --git a/Application/views/ga4/add_to_cart.tpl b/Application/views/ga4/add_to_cart.tpl index 83062ec..b1b13f2 100644 --- a/Application/views/ga4/add_to_cart.tpl +++ b/Application/views/ga4/add_to_cart.tpl @@ -5,6 +5,8 @@ [{capture assign=d3_ga4_add_to_cart}] [{block name="d3_ga4_add_to_basket"}] $("#toBasket").click(function(event) { + + [{*** Debug cases ***}] [{*event.preventDefault();*}] let iArtQuantity = $("#amountToBasket").val(); @@ -28,7 +30,6 @@ 'item_category_3':itemCategories[2] || '', 'item_category_4':itemCategories[3] || '', [{if false}] - [{* ??? what *}] 'item_list_name': 'Search Results', // If associated with a list selection. 'item_list_id': 'SR123', // If associated with a list selection. 'index': 1, // If associated with a list selection. diff --git a/Application/views/ga4/view_item.tpl b/Application/views/ga4/view_item.tpl deleted file mode 100644 index e44d842..0000000 --- a/Application/views/ga4/view_item.tpl +++ /dev/null @@ -1,26 +0,0 @@ -[{strip}] - [{* variable $gtmProduct is passed from parent tempalte *}] - [{assign var="gtmCurrency" value=$oView->getActCurrency()}] - [{assign var="gtmManufacturer" value=$gtmProduct->getManufacturer()}] - [{assign var="gtmCategory" value=$gtmProduct->getCategory()}] - -[{/strip}] \ No newline at end of file diff --git a/metadata.php b/metadata.php index d1e47e4..7f70821 100755 --- a/metadata.php +++ b/metadata.php @@ -65,6 +65,13 @@ $aModule = [ 'file' => '/Application/views/ga4/add_to_cart.tpl', 'position' => 150 ], + // details + [ + 'template' => 'page/details/inc/productmain.tpl', + 'block' => 'details_productmain_title', + 'file' => '/Application/views/blocks/view_item.tpl', + 'position' => 150 + ], // Lists // view_item_list [ From 527eec1355b1ea8993978dd57ba300cfefdbff82 Mon Sep 17 00:00:00 2001 From: MaxBUhe Date: Mon, 20 Mar 2023 11:01:03 +0100 Subject: [PATCH 2/2] bump changelog --- CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6fa20ab..23c5f08 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [2.3.3](https://git.d3data.de/D3Public/GoogleAnalytics4/compare/2.3.2...2.3.3) - 2023-03-20 +### Fixed +- metadata file path for view_item + ## [2.3.2](https://git.d3data.de/D3Public/GoogleAnalytics4/compare/2.2.2...2.3.2) - 2023-03-17 ### Added - Aggrosoft-Cookie-Consent compatibility