-
Notifications
You must be signed in to change notification settings - Fork 1
/
cms.xml
executable file
·49 lines (43 loc) · 2.76 KB
/
cms.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
<?xml version="1.0" ?>
<container xmlns="http://symfony.com/schema/dic/services"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://symfony.com/schema/dic/services http://symfony.com/schema/dic/services/services-1.0.xsd">
<services>
<!-- Shopware6 definition of the CMS use -->
<service id="boxalino.integration.context.cms"
class="Boxalino\RealTimeUserExperienceIntegration\Framework\Request\Context\Cms"
parent="boxalino.shopware.request.context.cms"
shared="false">
<call method="setRequestDefinition">
<argument type="service" id="Boxalino\RealTimeUserExperienceApi\Service\Api\Request\Definition\ListingRequestDefinitionInterface"/>
</call>
<!-- setWidget, setHitCount, setGroupBy and other data is inherited from the CMS element configuration -->
</service>
<!-- Shopware6 CMS loader extension with API call -->
<service id="boxalino.integration.loader.cms"
class="Boxalino\RealTimeUserExperience\Framework\Content\Page\ApiCmsLoader" parent="boxalino.shopware.content.page.cms"
shared="false">
<call method="setApiContext">
<argument type="service" id="boxalino.integration.context.cms"/>
</call>
</service>
<!-- CMS Loader event subscriber to be added when wanting to use it -->
<service id="Boxalino\RealTimeUserExperience\Framework\Content\Subscriber\ApiCmsLoaderSubscriber">
<argument type="service" id="boxalino.integration.loader.cms"/>
<argument type="service" id="Boxalino\RealTimeUserExperienceApi\Service\Api\Request\RequestInterface"/>
<argument type="service" id="event_dispatcher"/>
<argument type="service" id="Boxalino\RealTimeUserExperienceIntegration\Service\Logger"/>
<tag name="kernel.event_subscriber"/>
</service>
<!-- CacheStateSubscriber to avoid caching CMS pages loaded for ALL NAVIGATION PAGES -->
<service id="Boxalino\RealTimeUserExperienceIntegration\Core\Framework\Adapter\Cache\ApiNavigationCacheStateSubscriber">
<argument type="service" id="Boxalino\RealTimeUserExperienceApi\Service\Api\Util\ConfigurationInterface"/>
<tag name="kernel.event_subscriber"/>
</service>
<!-- CacheInvalidator to invalidate caching CMS pages loaded with narratives -->
<service id="Boxalino\RealTimeUserExperience\Core\Framework\Adapter\Cache\CmsCacheInvalidationSubscriber">
<argument type="service" id="Shopware\Core\Framework\Adapter\Cache\CacheInvalidator"/>
<tag name="kernel.event_subscriber"/>
</service>
</services>
</container>