Details
-
Story
-
Resolution: Unresolved
-
Medium
-
None
-
2.5.7
-
None
Description
Add a tool that, based on content view configuration, creates the matching field definitions.
Example
Query controller view configuration
gallery: controller: ez_query:locationQueryAction template: full/gallery.html.twig match: Identifier\ContentType: gallery params: query: query_type: LocationChildren parameters: parentLocationId: '@=location.id' contentTypeIdentifier: 'gallery' assign_results_to: images
Query field definition
- Content type: gallery (matcher Identifier\ContentType)
- Field def dentifier: images (assign_results_to)
- Query type: LocationChildren (query_type)
- Query type parameters: the contents of the parameters key.
The view configuration for the field can also be proposed:
content_query:
gallery_images:
match:
Identifier\ContentType: gallery
Identifier\FieldDefinition: images
template: 'content_query/gallery/images.html.twig'
What's left to do is create the template, based on the processing of the images variable in the gallery.html.twig template.