From 95de52600db134001e2015079e5815c4d399e67f Mon Sep 17 00:00:00 2001 From: MaxBUhe Date: Wed, 11 Jan 2023 14:43:13 +0100 Subject: [PATCH] add add_to_cart --- Application/views/ga4/add_to_cart.tpl | 79 ++++++++++++++++----------- metadata.php | 6 ++ 2 files changed, 54 insertions(+), 31 deletions(-) diff --git a/Application/views/ga4/add_to_cart.tpl b/Application/views/ga4/add_to_cart.tpl index a3d5e3a..37316b1 100644 --- a/Application/views/ga4/add_to_cart.tpl +++ b/Application/views/ga4/add_to_cart.tpl @@ -1,41 +1,58 @@ -[{strip}] - [{$gtmProduct|@var_dump}] - [{* 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 1d59119..574fd2a 100755 --- a/metadata.php +++ b/metadata.php @@ -130,6 +130,12 @@ $aModule = [ 'template' => 'page/search/search.tpl', 'block' => 'search_results', 'file' => '/Application/views/ga4/search.tpl' + ], + // add_to_cart + [ + 'template' => 'page/details/inc/productmain.tpl', + 'block' => 'details_productmain_tobasket', + 'file' => '/Application/views/ga4/add_to_cart.tpl' ] ], 'settings' => [