cleaning off branding
Cette révision appartient à :
Parent
d028f418ad
révision
bd17c3370d
@ -1,37 +0,0 @@
|
|||||||
<?php
|
|
||||||
/**
|
|
||||||
* [bla] tag-manager
|
|
||||||
* Copyright (C) 2018 bestlife AG
|
|
||||||
* info: oxid@bestlife.ag
|
|
||||||
*
|
|
||||||
* This program is free software;
|
|
||||||
* you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation;
|
|
||||||
* either version 3 of the License, or (at your option) any later version.
|
|
||||||
*
|
|
||||||
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
|
||||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
|
|
||||||
* You should have received a copy of the GNU General Public License along with this program; if not, see <http://www.gnu.org/licenses/>
|
|
||||||
**/
|
|
||||||
|
|
||||||
$aLang = [
|
|
||||||
'charset' => 'UTF-8',
|
|
||||||
|
|
||||||
|
|
||||||
// das hier wird nicht mehr benötigt, aber ich lasse es drin, falls doch
|
|
||||||
// leserliche Namen für product list performance (GA)
|
|
||||||
'VT_GTM_EE_productList' => 'Category',
|
|
||||||
'VT_GTM_EE_searchList' => 'Search',
|
|
||||||
'VT_GTM_EE_cross' => 'Crossselling',
|
|
||||||
'VT_GTM_EE_accessories' => 'Accessories',
|
|
||||||
'VT_GTM_EE_last' => 'Last Seen',
|
|
||||||
'VT_GTM_EE_bargainItems' => 'Offer of the Week',
|
|
||||||
'VT_GTM_EE_newItems' => 'Just Arrived',
|
|
||||||
'VT_GTM_EE_topBox' => 'Topseller',
|
|
||||||
// ab hier wird wieder benötigt
|
|
||||||
|
|
||||||
// Dimensionen im checkout
|
|
||||||
'VT_GTM_EE_LOGINOPTION' => 'Existing Customer',
|
|
||||||
'VT_GTM_EE_LOGINOPTION1' => 'Guest',
|
|
||||||
'VT_GTM_EE_LOGINOPTION2' => 'Existing Customer',
|
|
||||||
'VT_GTM_EE_LOGINOPTION3' => 'New Customer'
|
|
||||||
];
|
|
@ -25,22 +25,22 @@ input.confinput:hover {outline:3px solid #ff3600;}
|
|||||||
</style>';
|
</style>';
|
||||||
$aLang = [
|
$aLang = [
|
||||||
'charset' => 'UTF-8',
|
'charset' => 'UTF-8',
|
||||||
'SHOP_MODULE_vt_gtm_sContainerID' => 'Container ID',
|
'SHOP_MODULE_d3_gtm_sContainerID' => 'Container ID',
|
||||||
'SHOP_MODULE_GROUP_vt_gtm_settings' => 'Einstellungen',
|
'SHOP_MODULE_GROUP_d3_gtm_settings' => 'Einstellungen',
|
||||||
'SHOP_MODULE_vt_gtm_blGA4enab' => 'GA4 Aktivieren',
|
'SHOP_MODULE_d3_gtm_blGA4enab' => 'GA4 Aktivieren',
|
||||||
'SHOP_MODULE_vt_gtm_blUAenabled' => 'UA Aktivieren',
|
'SHOP_MODULE_d3_gtm_blUAenabled' => 'UA Aktivieren',
|
||||||
'SHOP_MODULE_vt_gtm_blEnableDebug' => 'Debug-Modus aktivieren',
|
'SHOP_MODULE_d3_gtm_blEnableDebug' => 'Debug-Modus aktivieren',
|
||||||
|
|
||||||
// for cookie manager settings
|
// for cookie manager settings
|
||||||
'SHOP_MODULE_GROUP_vt_gtm_settings_cookiemanager' => 'Cookie Manager Einstellungen',
|
'SHOP_MODULE_GROUP_d3_gtm_settings_cookiemanager' => 'Cookie Manager Einstellungen',
|
||||||
'SHOP_MODULE_vt_gtm_settings_hasOwnCookieManager' => 'Eigenen Cookie Manager nutzen?
|
'SHOP_MODULE_d3_gtm_settings_hasOwnCookieManager' => 'Eigenen Cookie Manager nutzen?
|
||||||
<strong style="color: red">Hinweis (Fragezeichen) lesen!</strong>',
|
<strong style="color: red">Hinweis (Fragezeichen) lesen!</strong>',
|
||||||
'HELP_SHOP_MODULE_vt_gtm_settings_hasOwnCookieManager' => 'Stellen Sie sicher, dass Sie ein Modul installiert haben,
|
'HELP_SHOP_MODULE_d3_gtm_settings_hasOwnCookieManager' => 'Stellen Sie sicher, dass Sie ein Modul installiert haben,
|
||||||
dass die Methode "blAcceptedCookie" implementiert.<br> Sollten Sie sich nicht sicher sein kontaktieren Sie Ihren
|
dass die Methode "blAcceptedCookie" implementiert.<br> Sollten Sie sich nicht sicher sein kontaktieren Sie Ihren
|
||||||
technischen Ansprechpartner.<br><br>
|
technischen Ansprechpartner.<br><br>
|
||||||
|
|
||||||
<strong>Wichtig!</strong> Das Aktivieren dieser Checkbox kann <u>ohne dem nötigen technischen Wissen</u> den Shop-Ablauf im Frontend stören!<hr>
|
<strong>Wichtig!</strong> Das Aktivieren dieser Checkbox kann <u>ohne dem nötigen technischen Wissen</u> den Shop-Ablauf im Frontend stören!<hr>
|
||||||
Die Checkbox muss nicht aktiviert werden, sofern die Cookies beispielsweise direkt via Google Cookie-Banner integriert werden.
|
Die Checkbox muss nicht aktiviert werden, sofern die Cookies beispielsweise direkt via Google Cookie-Banner integriert werden.
|
||||||
Bei Fragen <u>kontaktieren Sie bitte</u> auch hier einen entsprechenden technischen Ansprechpartner.',
|
Bei Fragen <u>kontaktieren Sie bitte</u> auch hier einen entsprechenden technischen Ansprechpartner.',
|
||||||
'SHOP_MODULE_vt_gtm_settings_cookieName' => 'Cookie-Name',
|
'SHOP_MODULE_d3_gtm_settings_cookieName' => 'Cookie-Name',
|
||||||
];
|
];
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
[{assign var="d3VtConfigObject" value=$oViewConf->getConfig()}]
|
[{assign var="d3VtConfigObject" value=$oViewConf->getConfig()}]
|
||||||
[{if $d3VtConfigObject->getConfigParam('vt_gtm_settings_hasOwnCookieManager')}]
|
[{if $d3VtConfigObject->getConfigParam('d3_gtm_settings_hasOwnCookieManager')}]
|
||||||
[{if $oViewConf->blAcceptedCookie($d3VtConfigObject->getConfigParam('vt_gtm_settings_cookieName'))}]
|
[{if $oViewConf->blAcceptedCookie($d3VtConfigObject->getConfigParam('d3_gtm_settings_cookieName'))}]
|
||||||
|
|
||||||
[{if $oViewConf->getGtmContainerId()}][{strip}]
|
[{if $oViewConf->getGtmContainerId()}][{strip}]
|
||||||
<!-- Google Tag Manager -->
|
<!-- Google Tag Manager -->
|
||||||
@ -46,7 +46,6 @@
|
|||||||
})(window, document, 'script', 'dataLayer', '[{$oViewConf->getGtmContainerId()}]');
|
})(window, document, 'script', 'dataLayer', '[{$oViewConf->getGtmContainerId()}]');
|
||||||
</script>
|
</script>
|
||||||
<!-- End Google Tag Manager -->
|
<!-- End Google Tag Manager -->
|
||||||
[{$oViewConf->triggerGA4events()}]
|
|
||||||
[{if $oViewConf->getTopActionClassName() === "alist" }]
|
[{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" }]
|
[{elseif $oViewConf->getTopActionClassName() === "details" }]
|
||||||
|
@ -8,7 +8,7 @@
|
|||||||
'checkout': {
|
'checkout': {
|
||||||
'actionField': {
|
'actionField': {
|
||||||
'step': 2,
|
'step': 2,
|
||||||
'option':'[{oxmultilang ident="VT_GTM_EE_LOGINOPTION"|cat:$oView->getLoginOption()}]'
|
'option':'[{oxmultilang ident="vt_GTM_EE_LOGINOPTION"|cat:$oView->getLoginOption()}]'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -30,7 +30,7 @@ class ViewConfig extends ViewConfig_parent
|
|||||||
{
|
{
|
||||||
if ($this->sContainerId === null)
|
if ($this->sContainerId === null)
|
||||||
{
|
{
|
||||||
$this->sContainerId = $this->getConfig()->getConfigParam('vt_gtm_sContainerID');
|
$this->sContainerId = $this->getConfig()->getConfigParam('d3_gtm_sContainerID');
|
||||||
}
|
}
|
||||||
return $this->sContainerId;
|
return $this->sContainerId;
|
||||||
}
|
}
|
||||||
@ -41,7 +41,7 @@ class ViewConfig extends ViewConfig_parent
|
|||||||
{
|
{
|
||||||
if ($this->blGA4enabled === null)
|
if ($this->blGA4enabled === null)
|
||||||
{
|
{
|
||||||
$this->sContainerId = $this->getConfig()->getConfigParam('vt_gtm_blEnableGA4');
|
$this->sContainerId = $this->getConfig()->getConfigParam('d3_gtm_blEnableGA4');
|
||||||
}
|
}
|
||||||
|
|
||||||
return $this->blGA4enabled;
|
return $this->blGA4enabled;
|
||||||
@ -81,40 +81,11 @@ class ViewConfig extends ViewConfig_parent
|
|||||||
//'httpref' => $_SERVER["HTTP_REFERER"] ?? "unknown"
|
//'httpref' => $_SERVER["HTTP_REFERER"] ?? "unknown"
|
||||||
];
|
];
|
||||||
|
|
||||||
#return json_encode([$dataLayer], JSON_PRETTY_PRINT);
|
return json_encode([$dataLayer], JSON_PRETTY_PRINT);
|
||||||
|
|
||||||
unset($dataLayer["user"]["http"]); // das brauchen wir hier nicht
|
unset($dataLayer["user"]["http"]); // das brauchen wir hier nicht
|
||||||
|
|
||||||
|
|
||||||
return json_encode([$dataLayer], JSON_PRETTY_PRINT);
|
|
||||||
/*
|
|
||||||
// --- Produktdaten ---
|
|
||||||
$transactionProducts = [];
|
|
||||||
foreach($oOrder->getOrderArticles() as $_prod ) $transactionProducts[] = [
|
|
||||||
'name' => '', // (erforderlich) Produktname String
|
|
||||||
'sku' => '', // (erforderlich) Produkt-SKU String
|
|
||||||
'category' => '', // (optional) Produktkategorie String
|
|
||||||
'price' => '', // (erforderlich) Preis pro Einheit Numerischer Wert
|
|
||||||
'quantity' => '' // (erforderlich) Anzahl der Artikel Numerischer Wert
|
|
||||||
];
|
|
||||||
|
|
||||||
// --- Transaktionsdaten ---
|
|
||||||
|
|
||||||
$dataLayer['transactionId'] = $oOrder->oxorder__oxordernr->value; // (erforderlich) Eindeutige Transaktionskennung String
|
|
||||||
$dataLayer['transactionAffiliation'] = $oShop->oxshops__oxname->value; // (optional) Partner oder Geschäft String
|
|
||||||
$dataLayer['transactionTotal'] = $oOrder->oxorder__oxtotalordersum->value; // (erforderlich) Gesamtwert der Transaktion Numerischer Wert
|
|
||||||
$dataLayer['transactionShipping'] = $oOrder->oxorder__oxdelcost->value; // (optional) Versandkosten für die Transaktion Numerischer Wert
|
|
||||||
$dataLayer['transactionTax'] = ''; // (optional) Steuerbetrag für die Transaktion Numerischer Wert
|
|
||||||
$dataLayer['transactionProducts'] = $transactionProducts; // (optional) Liste der bei der Transaktion erworbenen Artikel Array von Produktobjekten
|
|
||||||
*/
|
|
||||||
}
|
|
||||||
|
|
||||||
public function triggerGA4events()
|
|
||||||
{
|
|
||||||
// general events
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
public function isPromotionList($listId)
|
public function isPromotionList($listId)
|
||||||
{
|
{
|
||||||
$oConfig = Registry::getConfig();
|
$oConfig = Registry::getConfig();
|
||||||
|
28
metadata.php
28
metadata.php
@ -46,10 +46,10 @@ $aModule = [
|
|||||||
'ga4_view_item_list.tpl' => 'd3/googleanalytics4/Application/views/ga4/view_item_list.tpl',
|
'ga4_view_item_list.tpl' => 'd3/googleanalytics4/Application/views/ga4/view_item_list.tpl',
|
||||||
'ga4_view_promotion.tpl' => 'd3/googleanalytics4/Application/views/ga4/view_promotion.tpl',
|
'ga4_view_promotion.tpl' => 'd3/googleanalytics4/Application/views/ga4/view_promotion.tpl',
|
||||||
/*
|
/*
|
||||||
'gtm_ua_impression' => 'vt/GoogleTagManager/Application/views/ua/impression.tpl'
|
'gtm_ua_impression' => 'd3/GoogleTagManager/Application/views/ua/impression.tpl'
|
||||||
'gtm_view_promotion.tpl' => 'vt/GoogleTagManager/Application/views/view_promotion.tpl',
|
'gtm_view_promotion.tpl' => 'd3/GoogleTagManager/Application/views/view_promotion.tpl',
|
||||||
'gtm_select_promotion.tpl' => 'vt/GoogleTagManager/Application/views/select_promotion.tpl',
|
'gtm_select_promotion.tpl' => 'd3/GoogleTagManager/Application/views/select_promotion.tpl',
|
||||||
'gtm_begin_checkout.tpl' => 'vt/GoogleTagManager/Application/views/begin_checkout.tpl',
|
'gtm_begin_checkout.tpl' => 'd3/GoogleTagManager/Application/views/begin_checkout.tpl',
|
||||||
*/
|
*/
|
||||||
],
|
],
|
||||||
'blocks' => [
|
'blocks' => [
|
||||||
@ -145,36 +145,36 @@ $aModule = [
|
|||||||
],
|
],
|
||||||
'settings' => [
|
'settings' => [
|
||||||
[
|
[
|
||||||
'group' => 'vt_gtm_settings',
|
'group' => 'd3_gtm_settings',
|
||||||
'name' => 'vt_gtm_sContainerID',
|
'name' => 'd3_gtm_sContainerID',
|
||||||
'type' => 'str',
|
'type' => 'str',
|
||||||
'value' => 'GTM-',
|
'value' => 'GTM-',
|
||||||
'position' => 0
|
'position' => 0
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'group' => 'vt_gtm_settings',
|
'group' => 'd3_gtm_settings',
|
||||||
'name' => 'vt_gtm_blGA4enab',
|
'name' => 'd3_gtm_sContainerID',
|
||||||
'type' => 'bool',
|
'type' => 'bool',
|
||||||
'value' => true,
|
'value' => true,
|
||||||
'position' => 1
|
'position' => 1
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'group' => 'vt_gtm_settings',
|
'group' => 'd3_gtm_settings',
|
||||||
'name' => 'vt_gtm_blEnableDebug',
|
'name' => 'd3_gtm_blEnableDebug',
|
||||||
'type' => 'bool',
|
'type' => 'bool',
|
||||||
'value' => false,
|
'value' => false,
|
||||||
'position' => 999
|
'position' => 999
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'group' => 'vt_gtm_settings_cookiemanager',
|
'group' => 'd3_gtm_settings_cookiemanager',
|
||||||
'name' => 'vt_gtm_settings_hasOwnCookieManager',
|
'name' => 'd3_gtm_settings_hasOwnCookieManager',
|
||||||
'type' => 'bool',
|
'type' => 'bool',
|
||||||
'value' => false,
|
'value' => false,
|
||||||
'position' => 999
|
'position' => 999
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'group' => 'vt_gtm_settings_cookiemanager',
|
'group' => 'd3_gtm_settings_cookiemanager',
|
||||||
'name' => 'vt_gtm_settings_cookieName',
|
'name' => 'd3_gtm_settings_cookieName',
|
||||||
'type' => 'str',
|
'type' => 'str',
|
||||||
'value' => 'example',
|
'value' => 'example',
|
||||||
'position' => 999
|
'position' => 999
|
||||||
|
Chargement…
Référencer dans un nouveau ticket
Block a user