This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace AppBundle\Queries; | |
use eZ\Publish\Core\QueryType\QueryType; | |
use Netgen\EzPlatformSiteApi\API\LoadService; | |
use Netgen\TagsBundle\API\Repository\Values\Content\Query\Criterion\TagId; | |
use Netgen\TagsBundle\API\Repository\Values\Tags\Tag; | |
use eZ\Publish\API\Repository\Values\Content\Query\Criterion; | |
use eZ\Publish\API\Repository\Values\Content\Query\SortClause; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
app.queries.lastest_related_recipies: | |
class: AppBundle\Queries\LatestRelatedRecipes | |
arguments: | |
- '@netgen.ezplatform_site.load_service' | |
tags: | |
- { name: ezpublish.query_type } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace AppBundle\Queries; | |
use eZ\Publish\Core\QueryType\OptionsResolverBasedQueryType; | |
use Netgen\EzPlatformSiteApi\API\LoadService; | |
use Netgen\TagsBundle\API\Repository\Values\Content\Query\Criterion\TagId; | |
use Netgen\TagsBundle\API\Repository\Values\Tags\Tag; | |
use eZ\Publish\API\Repository\Values\Content\Query\Criterion; | |
use eZ\Publish\API\Repository\Values\Content\Query\SortClause; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{% if recipies is defined and recipies is not empty %} | |
<h2 class="section-title section-title-centered title">Latest recipies</h2> | |
{% for recipie in recipies %} | |
{{ render( | |
controller( | |
'ng_content:viewAction', { | |
'content': recipie.content, | |
'location': recipie, | |
'viewType': 'standard', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ng_recipe: | |
template: "@ezdesign/content/full/ng_recipe.html.twig" | |
controller: "ez_query:contentQueryAction" | |
match: | |
Identifier\ContentType: ng_recipe | |
params: | |
query: | |
query_type: 'LatestRelatedRecipies' | |
parameters: | |
recipe_content_id: "@=content.id" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{% if recipes is defined and recipes.totalCount > 0 %} | |
<h2 class="section-title section-title-centered title">Latest recipes</h2> | |
{% for recipe in recipes.searchHits %} | |
{{ render( | |
controller( | |
'ez_content:viewAction', { | |
'contentId': recipe.id, | |
'locationId': recipe.contentInfo.mainLocationId, | |
'viewType': 'standard', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ng_recipe: | |
template: "@ezdesign/content/full/ng_recipe.html.twig" | |
match: | |
Identifier\ContentType: ng_recipe | |
queries: | |
latest_recipes: | |
query_type: SiteAPI:Content/Relations/TagFields | |
max_per_page: 4 | |
page: '@=queryParam("page", 1)' | |
parameters: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{% set recipes = ng_query( 'latest_recipes' ) %} | |
{% if recipes.getNbResults > 0 %} | |
<h2 class="section-title section-title-centered title">Latest recipes</h2> | |
{% for recipe in recipes %} | |
{{ render( | |
controller( | |
'ng_content:viewAction', { | |
'content': recipe, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
declare(strict_types=1); | |
namespace Netgen\InformationCollection\PolicyProvider; | |
use eZ\Bundle\EzPublishCoreBundle\DependencyInjection\Configuration\ConfigBuilderInterface; | |
use eZ\Bundle\EzPublishCoreBundle\DependencyInjection\Security\PolicyProvider\PolicyProviderInterface; | |
class InformationCollectionPolicyProvider implements PolicyProviderInterface |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$configBuilder->addConfig([ | |
'infocollector' => [ | |
'read' => [], | |
'delete' => [], | |
'anonymize' => [], | |
], | |
]); |