Hallo Zusammen,
ich habe für mich ein NodeType ("Geosphere.Apex:Carousel
"), wie in den verschiedenen Tutorials gezeigt wird, mit der Funktion eines Carousels umgesetzt. Dieses Funktioniert auch wenn ich es zum Beispiel im “normalen” “Content.Collection(main)
” einbinde. Da wird mir das Carousel richtig dargestellt.
Jetzt möchte ich aber dieses “Geosphere.Apex:Carousel
” als Teaserelement als einziges Content anbieten. Analog einer “Sidebar”.
Leider wird da mir das Carousel nicht angezeigt. Anscheinend stimmt was mit dem Pfad zum "carluselItems"
nicht??
Wenn ich im “PAGE.YAML” für den myTag1:
den Typen 'Neos.Neos.ContentCollection'
eintrage, dann funktioniert es wieder.
main:
type: 'Neos.Neos:ContentCollection'
Aber ich möchte hier keine anderen Contents eintragen lassen. Es soll mir nur beim Erzeugen der Seite gleich an meiner gewünschten Stelle ein Carousel angeboten werden.
Vielleicht kann mir hier einer weiter helfen…
viele Grüße
Werner
No content collection of type Neos.Neos:ContentCollection could be found in the current node (/sites/geosphere-apex) or at the path "carouselItems". You might want to adjust your node type configuration and create the missing child node through the "flow node:repair --node-type Geosphere.Apex:Page" command.
Template HTML
{content.test -> f:format.raw()}
Page.yaml
'Geosphere.Apex:Page':
superTypes:
'Neos.Neos:Document': true
ui:
icon: 'icon-file'
label: 'Geosphere.Apex Custom Page'
childNodes:
main:
type: 'Neos.Neos:ContentCollection'
myTag1:
type: 'Geosphere.Apex:Carousel'
NodeTypes.Carousel.yaml
prototype(Geosphere.Apex:Carousel) {
carouselItems = Neos.Neos:ContentCollection {
nodePath = ‘carouselItems’
content.iterationName = ‘carouselItemsIteration’
attributes.class = ‘carousel-inner’
attributes.class.@process.collectionClass >
}
carouselItemArray = ${q(node).children(‘carouselItems’).children(’[instanceof Geosphere.Apex:CarouselItem]’)}
}
Page.fusion
prototype(Geosphere.Apex:Page) < prototype(Geosphere.Apex:DefaultPage) {
body {
// These are your content areas, you can define as many as you want, just name them and define the nodePath.
content {
// The default content collection
main = Neos.Neos:PrimaryContent {
nodePath = 'main'
}
test = Geosphere.Apex:Carousel {
nodePath = 'myTag1'
}
}
}
}