[Added] add_to_cart to recommlist, wishlist, noticelist, Class-Extensions for corresponding templates
This commit is contained in:
parent
a88fa570a8
commit
ab6b7f7454
18
Application/views/tpl/page/account/d3gtmnoticelist.tpl
Normal file
18
Application/views/tpl/page/account/d3gtmnoticelist.tpl
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
[{capture append="oxidBlock_content"}]
|
||||||
|
[{assign var="template_title" value="MY_WISH_LIST"|oxmultilangassign}]
|
||||||
|
<h1 class="page-header">[{oxmultilang ident="MY_WISH_LIST"}]</h1>
|
||||||
|
|
||||||
|
[{if $oView->getNoticeProductList()}]
|
||||||
|
[{include file="widget/product/list.tpl" type="line" listId="noticelistProductList" title="" products=$oView->getNoticeProductList() removeFunction="tonoticelist" owishid=$oxcmp_user->oxuser__oxid->value}]
|
||||||
|
[{else}]
|
||||||
|
<p class="alert alert-info">[{oxmultilang ident="WISH_LIST_EMPTY"}]</p>
|
||||||
|
[{/if}]
|
||||||
|
|
||||||
|
[{include file="addtocart.tpl" htmlIdAmountOfArticles='#amountToBasket'}]
|
||||||
|
|
||||||
|
[{insert name="oxid_tracker" title=$template_title}]
|
||||||
|
[{/capture}]
|
||||||
|
[{capture append="oxidBlock_sidebar"}]
|
||||||
|
[{include file="page/account/inc/account_menu.tpl" active_link="noticelist"}]
|
||||||
|
[{/capture}]
|
||||||
|
[{include file="layout/page.tpl" sidebar="Left"}]
|
@ -0,0 +1,32 @@
|
|||||||
|
[{capture append="oxidBlock_content"}]
|
||||||
|
[{assign var="template_title" value="LISTMANIA"|oxmultilangassign}]
|
||||||
|
[{assign var="_actvrecommlist" value=$oView->getActiveRecommList()}]
|
||||||
|
|
||||||
|
<h1 class="page-header">[{oxmultilang ident="LISTMANIA"}]</h1>
|
||||||
|
|
||||||
|
[{if $oView->isSavedList()}]
|
||||||
|
[{assign var="_statusMessage" value="LISTMANIA_LIST_SAVED"|oxmultilangassign}]
|
||||||
|
[{include file="message/success.tpl" statusMessage=$_statusMessage}]
|
||||||
|
[{/if}]
|
||||||
|
|
||||||
|
[{block name="account_redommendationlist_content"}]
|
||||||
|
|
||||||
|
[{include file="form/recommendation_edit.tpl" actvrecommlist=$_actvrecommlist}]
|
||||||
|
|
||||||
|
<hr>
|
||||||
|
|
||||||
|
[{if !$oView->getActiveRecommList()}]
|
||||||
|
[{assign var="blEdit" value=true}]
|
||||||
|
[{include file="page/recommendations/inc/list.tpl"}]
|
||||||
|
[{/if}]
|
||||||
|
[{/block}]
|
||||||
|
|
||||||
|
[{include file="addtocart.tpl" htmlIdAmountOfArticles='#amountToBasket'}]
|
||||||
|
|
||||||
|
[{insert name="oxid_tracker" title=$template_title}]
|
||||||
|
[{/capture}]
|
||||||
|
[{capture append="oxidBlock_sidebar"}]
|
||||||
|
[{include file="page/account/inc/account_menu.tpl" active_link="recommendationlist"}]
|
||||||
|
[{/capture}]
|
||||||
|
[{include file="layout/page.tpl" sidebar="Left"}]
|
||||||
|
|
44
Application/views/tpl/page/account/d3gtmwishlist.tpl
Normal file
44
Application/views/tpl/page/account/d3gtmwishlist.tpl
Normal file
@ -0,0 +1,44 @@
|
|||||||
|
[{capture append="oxidBlock_content"}]
|
||||||
|
[{assign var="template_title" value="MY_GIFT_REGISTRY"|oxmultilangassign}]
|
||||||
|
[{if !$oView->getWishListUsers() && $oView->getWishListSearchParam()}]
|
||||||
|
[{assign var="_statusMessage" value="MESSAGE_SORRY_NO_GIFT_REGISTRY"|oxmultilangassign}]
|
||||||
|
[{include file="message/error.tpl" statusMessage=$_statusMessage}]
|
||||||
|
[{/if}]
|
||||||
|
[{assign var="editval" value=$oView->getEnteredData()}]
|
||||||
|
[{if $oView->isWishListEmailSent()}]
|
||||||
|
[{assign var="_statusMessage" value="GIFT_REGISTRY_SENT_SUCCESSFULLY"|oxmultilangassign:$editval->rec_email}]
|
||||||
|
[{include file="message/notice.tpl" statusMessage=$_statusMessage}]
|
||||||
|
[{/if}]
|
||||||
|
|
||||||
|
<h1 class="page-header">[{$oView->getTitle()}]</h1>
|
||||||
|
|
||||||
|
<div class="wishlist-search">
|
||||||
|
[{include file="form/wishlist_search.tpl" searchClass="account_wishlist"}]
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<hr>
|
||||||
|
|
||||||
|
<div class="wishlist">
|
||||||
|
[{if $oView->getWishList()}]
|
||||||
|
[{include file="form/wishlist_publish.tpl"}]
|
||||||
|
<hr>
|
||||||
|
[{include file="form/wishlist_suggest.tpl"}]
|
||||||
|
[{/if}]
|
||||||
|
</div>
|
||||||
|
|
||||||
|
[{if $oView->getWishList()}]
|
||||||
|
[{include file="widget/product/list.tpl" type="line" listId="wishlistProductList" title="" products=$oView->getWishProductList() removeFunction="towishlist" toBasketFunction="tobasket" owishid=$oxcmp_user->oxuser__oxid->value}]
|
||||||
|
[{else}]
|
||||||
|
<p class="alert alert-info">
|
||||||
|
[{oxmultilang ident="GIFT_REGISTRY_EMPTY"}]
|
||||||
|
</p>
|
||||||
|
[{/if}]
|
||||||
|
|
||||||
|
[{include file="addtocart.tpl" htmlIdAmountOfArticles='#amountToBasket'}]
|
||||||
|
|
||||||
|
[{insert name="oxid_tracker" title=$template_title}]
|
||||||
|
[{/capture}]
|
||||||
|
[{capture append="oxidBlock_sidebar"}]
|
||||||
|
[{include file="page/account/inc/account_menu.tpl" active_link="wishlist"}]
|
||||||
|
[{/capture}]
|
||||||
|
[{include file="layout/page.tpl" sidebar="Left"}]
|
@ -24,6 +24,9 @@ namespace D3\GoogleAnalytics4\Modules\Application\Model{
|
|||||||
|
|
||||||
namespace D3\GoogleAnalytics4\Modules\Application\Controller{
|
namespace D3\GoogleAnalytics4\Modules\Application\Controller{
|
||||||
|
|
||||||
|
use OxidEsales\Eshop\Application\Controller\AccountNoticeListController;
|
||||||
|
use OxidEsales\Eshop\Application\Controller\AccountRecommlistController;
|
||||||
|
use OxidEsales\Eshop\Application\Controller\AccountWishlistController;
|
||||||
use OxidEsales\Eshop\Application\Controller\ArticleListController;
|
use OxidEsales\Eshop\Application\Controller\ArticleListController;
|
||||||
|
|
||||||
class BasketController_parent extends \OxidEsales\Eshop\Application\Controller\BasketController {}
|
class BasketController_parent extends \OxidEsales\Eshop\Application\Controller\BasketController {}
|
||||||
@ -32,6 +35,12 @@ namespace D3\GoogleAnalytics4\Modules\Application\Controller{
|
|||||||
class ArticleListController_AddToCartHelpMethods_parent extends ArticleListController {}
|
class ArticleListController_AddToCartHelpMethods_parent extends ArticleListController {}
|
||||||
|
|
||||||
class ArticleDetailsController_parent extends \OxidEsales\Eshop\Application\Controller\ArticleDetailsController {}
|
class ArticleDetailsController_parent extends \OxidEsales\Eshop\Application\Controller\ArticleDetailsController {}
|
||||||
|
|
||||||
|
class d3GtmAccountNoticeListController_parent extends AccountNoticeListController {}
|
||||||
|
|
||||||
|
class d3GtmAccountRecommlistController_parent extends AccountRecommlistController {}
|
||||||
|
|
||||||
|
class d3GtmAccountWishlistController_parent extends AccountWishlistController {}
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace D3\GoogleAnalytics4\Modules\Application\Component{
|
namespace D3\GoogleAnalytics4\Modules\Application\Component{
|
||||||
|
@ -0,0 +1,17 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace D3\GoogleAnalytics4\Modules\Application\Controller;
|
||||||
|
|
||||||
|
class d3GtmAccountNoticeListController extends d3GtmAccountNoticeListController_parent
|
||||||
|
{
|
||||||
|
protected $_sThisTemplate = 'page/account/d3gtmnoticelist.tpl';
|
||||||
|
|
||||||
|
public function render()
|
||||||
|
{
|
||||||
|
$return = parent::render();
|
||||||
|
|
||||||
|
$this->addTplParam('d3CmpBasket', $this->getComponent('oxcmp_basket'));
|
||||||
|
|
||||||
|
return $return;
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,17 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace D3\GoogleAnalytics4\Modules\Application\Controller;
|
||||||
|
|
||||||
|
class d3GtmAccountRecommlistController extends d3GtmAccountRecommlistController_parent
|
||||||
|
{
|
||||||
|
protected $_sThisTemplate = 'page/account/d3gtmrecommendationlist.tpl';
|
||||||
|
|
||||||
|
public function render()
|
||||||
|
{
|
||||||
|
$return = parent::render();
|
||||||
|
|
||||||
|
$this->addTplParam('d3CmpBasket', $this->getComponent('oxcmp_basket'));
|
||||||
|
|
||||||
|
return $return;
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,17 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace D3\GoogleAnalytics4\Modules\Application\Controller;
|
||||||
|
|
||||||
|
class d3GtmAccountWishlistController extends d3GtmAccountWishlistController_parent
|
||||||
|
{
|
||||||
|
protected $_sThisTemplate = 'page/account/d3gtmwishlist.tpl';
|
||||||
|
|
||||||
|
public function render()
|
||||||
|
{
|
||||||
|
$return = parent::render();
|
||||||
|
|
||||||
|
$this->addTplParam('d3CmpBasket', $this->getComponent('oxcmp_basket'));
|
||||||
|
|
||||||
|
return $return;
|
||||||
|
}
|
||||||
|
}
|
36
metadata.php
36
metadata.php
@ -4,12 +4,18 @@ use D3\GoogleAnalytics4\Modules\Application\Component\d3GtmBasketComponentExtens
|
|||||||
use D3\GoogleAnalytics4\Modules\Application\Controller\ArticleDetailsController;
|
use D3\GoogleAnalytics4\Modules\Application\Controller\ArticleDetailsController;
|
||||||
use D3\GoogleAnalytics4\Modules\Application\Controller\ArticleListController_AddToCartHelpMethods;
|
use D3\GoogleAnalytics4\Modules\Application\Controller\ArticleListController_AddToCartHelpMethods;
|
||||||
use D3\GoogleAnalytics4\Modules\Application\Controller\BasketController;
|
use D3\GoogleAnalytics4\Modules\Application\Controller\BasketController;
|
||||||
|
use D3\GoogleAnalytics4\Modules\Application\Controller\d3GtmAccountNoticeListController;
|
||||||
|
use D3\GoogleAnalytics4\Modules\Application\Controller\d3GtmAccountRecommlistController;
|
||||||
|
use D3\GoogleAnalytics4\Modules\Application\Controller\d3GtmAccountWishlistController;
|
||||||
use D3\GoogleAnalytics4\Modules\Application\Controller\ThankYouController;
|
use D3\GoogleAnalytics4\Modules\Application\Controller\ThankYouController;
|
||||||
use D3\GoogleAnalytics4\Modules\Application\Model\Basket as Basket;
|
use D3\GoogleAnalytics4\Modules\Application\Model\Basket as Basket;
|
||||||
use D3\GoogleAnalytics4\Modules\Application\Model\Category as Category;
|
use D3\GoogleAnalytics4\Modules\Application\Model\Category as Category;
|
||||||
use D3\GoogleAnalytics4\Modules\Application\Model\Manufacturer as Manufacturer;
|
use D3\GoogleAnalytics4\Modules\Application\Model\Manufacturer as Manufacturer;
|
||||||
use D3\GoogleAnalytics4\Modules\Core\ViewConfig;
|
use D3\GoogleAnalytics4\Modules\Core\ViewConfig;
|
||||||
use OxidEsales\Eshop\Application\Component\BasketComponent as OEBasketComponent;
|
use OxidEsales\Eshop\Application\Component\BasketComponent as OEBasketComponent;
|
||||||
|
use OxidEsales\Eshop\Application\Controller\AccountNoticeListController as OEAccountNoticeListController;
|
||||||
|
use OxidEsales\Eshop\Application\Controller\AccountRecommlistController as OEAccountRecommlistController;
|
||||||
|
use OxidEsales\Eshop\Application\Controller\AccountWishlistController as OEAccountWishlistController;
|
||||||
use OxidEsales\Eshop\Application\Controller\ArticleDetailsController as OEArticleDetailsController;
|
use OxidEsales\Eshop\Application\Controller\ArticleDetailsController as OEArticleDetailsController;
|
||||||
use OxidEsales\Eshop\Application\Controller\ArticleListController as OEArticleListController;
|
use OxidEsales\Eshop\Application\Controller\ArticleListController as OEArticleListController;
|
||||||
use OxidEsales\Eshop\Application\Controller\BasketController as OEBasketController;
|
use OxidEsales\Eshop\Application\Controller\BasketController as OEBasketController;
|
||||||
@ -39,18 +45,28 @@ $aModule = [
|
|||||||
'email' => 'support@shopmodule.com',
|
'email' => 'support@shopmodule.com',
|
||||||
'url' => 'https://www.oxidmodule.com/',
|
'url' => 'https://www.oxidmodule.com/',
|
||||||
'extend' => [
|
'extend' => [
|
||||||
OEViewConfig::class => ViewConfig::class,
|
OEViewConfig::class => ViewConfig::class,
|
||||||
OECategory::class => Category::class,
|
OECategory::class => Category::class,
|
||||||
OEBasket::class => Basket::class,
|
OEBasket::class => Basket::class,
|
||||||
OEBasketController::class => BasketController::class,
|
OEBasketController::class => BasketController::class,
|
||||||
OEManufacturer::class => Manufacturer::class,
|
OEManufacturer::class => Manufacturer::class,
|
||||||
OEThankYouController::class => ThankYouController::class,
|
OEThankYouController::class => ThankYouController::class,
|
||||||
OEArticleListController::class => ArticleListController_AddToCartHelpMethods::class,
|
OEArticleListController::class => ArticleListController_AddToCartHelpMethods::class,
|
||||||
OEBasketComponent::class => d3GtmBasketComponentExtension::class,
|
OEBasketComponent::class => d3GtmBasketComponentExtension::class,
|
||||||
OEArticleDetailsController::class => ArticleDetailsController::class
|
OEArticleDetailsController::class => ArticleDetailsController::class,
|
||||||
|
OEAccountNoticeListController::class => d3GtmAccountNoticeListController::class,
|
||||||
|
OEAccountRecommlistController::class => d3GtmAccountRecommlistController::class,
|
||||||
|
OEAccountWishlistController::class => d3GtmAccountWishlistController::class
|
||||||
],
|
],
|
||||||
'templates' => [
|
'templates' => [
|
||||||
'addtocart.tpl' => 'd3/googleanalytics4/Application/views/ga4/add_to_cart.tpl'
|
// own callable files
|
||||||
|
'addtocart.tpl' => 'd3/googleanalytics4/Application/views/ga4/add_to_cart.tpl',
|
||||||
|
|
||||||
|
// complete overwritten file of OXID-Originals
|
||||||
|
// the path of the template-name is the original path to the file in OXID-context from tpl/->
|
||||||
|
'page/account/d3gtmnoticelist.tpl' => 'd3/googleanalytics4/Application/views/tpl/page/account/d3gtmnoticelist.tpl',
|
||||||
|
'page/account/d3gtmrecommendationlist.tpl' => 'd3/googleanalytics4/Application/views/tpl/page/account/d3gtmrecommendationlist.tpl',
|
||||||
|
'page/account/d3gtmwishlist.tpl' => 'd3/googleanalytics4/Application/views/tpl/page/account/d3gtmwishlist.tpl',
|
||||||
],
|
],
|
||||||
'blocks' => [
|
'blocks' => [
|
||||||
// tag manager js
|
// tag manager js
|
||||||
|
Loading…
Reference in New Issue
Block a user