diff --git a/Application/views/admin/de/module_options.php b/Application/views/admin/de/module_options.php index fcee85c..46ce86a 100755 --- a/Application/views/admin/de/module_options.php +++ b/Application/views/admin/de/module_options.php @@ -32,4 +32,17 @@ $aLang = [ 'SHOP_MODULE_vt_gtm_sMpapisecret' => 'Map ist Geheim??', 'SHOP_MODULE_vt_gtm_aPromotionlistIDs' => 'Promotion Produktlisten IDs
Weitere Infos zu dieser Einstellung: Modui-Wiki
', 'SHOP_MODULE_vt_gtm_blEnableDebug' => 'Debug-Modus aktivieren', + + // for cookie manager settings + 'SHOP_MODULE_GROUP_vt_gtm_settings_cookiemanager' => 'Cookie Manager Einstellungen', + 'SHOP_MODULE_vt_gtm_settings_hasOwnCookieManager' => 'Eigenen Cookie Manager nutzen? + Hinweis (Fragezeichen) lesen!', + 'HELP_SHOP_MODULE_vt_gtm_settings_hasOwnCookieManager' => 'Stellen Sie sicher, dass Sie ein Modul installiert haben, + dass die Methode "blAcceptedCookie" implementiert.
Sollten Sie sich nicht sicher sein, kontaktieren Sie Ihren + technischen Ansprechpartner.

+ + Diese Möglichkeit zu aktivieren, ohne dem nötigen technischen Wissen kann den Shop-Ablauf (Frontend) stören.
+ Diese Möglichkeit kann vernachlässigt werden, sofern die Cookies beispielsweise direkt via Google handhabt werden. + Bei Fragen kontaktieren Sie bitte auch hier einen entsprechenden technischen Ansprechpartner.', + 'SHOP_MODULE_vt_gtm_settings_cookieName' => 'Cookie-Name', ]; diff --git a/Application/views/blocks/_gtm_js.tpl b/Application/views/blocks/_gtm_js.tpl index 3539472..981c4a7 100755 --- a/Application/views/blocks/_gtm_js.tpl +++ b/Application/views/blocks/_gtm_js.tpl @@ -1,25 +1,57 @@ -[{if $oViewConf->getGtmContainerId()}][{strip}] - - + + [{$oViewConf->triggerGA4events()}] + [{if $oViewConf->getTopActionClassName() === "alist" }] + [{* include file="ga4_view_item_list.tpl" gtmCategory=$oView->getActiveCategory() gtmProducts=$oView->getArticleList() listtype=$oView->getListType() *}] + [{elseif $oViewConf->getTopActionClassName() === "details" }] + [{* include file="ga4_view_item.tpl" gtmProduct=$oView->getProduct() *}] + [{elseif $oViewConf->getTopActionClassName() === "search" }] + [{elseif $oViewConf->getTopActionClassName() === "basket" }] + + [{/if}] + [{/strip}][{/if}] + [{/if}] +[{else}] + [{if $oViewConf->getGtmContainerId()}][{strip}] + + [{$oViewConf->triggerGA4events()}] [{if $oViewConf->getTopActionClassName() === "alist" }] - [{* include file="ga4_view_item_list.tpl" gtmCategory=$oView->getActiveCategory() gtmProducts=$oView->getArticleList() listtype=$oView->getListType() *}] + [{* include file="ga4_view_item_list.tpl" gtmCategory=$oView->getActiveCategory() gtmProducts=$oView->getArticleList() listtype=$oView->getListType() *}] [{elseif $oViewConf->getTopActionClassName() === "details" }] - [{* include file="ga4_view_item.tpl" gtmProduct=$oView->getProduct() *}] + [{* include file="ga4_view_item.tpl" gtmProduct=$oView->getProduct() *}] [{elseif $oViewConf->getTopActionClassName() === "search" }] [{elseif $oViewConf->getTopActionClassName() === "basket" }] [{/if}] -[{/strip}][{/if}] + [{/strip}][{/if}] +[{/if}] + [{$smarty.block.parent}] diff --git a/metadata.php b/metadata.php index d2f098d..35368ce 100755 --- a/metadata.php +++ b/metadata.php @@ -182,7 +182,20 @@ $aModule = [ 'type' => 'bool', 'value' => false, 'position' => 999 - ] - + ], + [ + 'group' => 'vt_gtm_settings_cookiemanager', + 'name' => 'vt_gtm_settings_hasOwnCookieManager', + 'type' => 'bool', + 'value' => false, + 'position' => 999 + ], + [ + 'group' => 'vt_gtm_settings_cookiemanager', + 'name' => 'vt_gtm_settings_cookieName', + 'type' => 'str', + 'value' => 'example', + 'position' => 999 + ], ] ]; \ No newline at end of file