Do not render list of typo3 or topics if not available in blog post

header
This commit is contained in:
Daniel Siepmann 2020-01-10 16:24:42 +01:00
parent 3cbe62319e
commit 6cd31a00a3

View file

@ -7,36 +7,41 @@
then: '<a href="{link}">{title}</a>', then: '<a href="{link}">{title}</a>',
else: title else: title
)}</h1> )}</h1>
<p> <p>
Published: <time>{blogPost.lastUpdated -> f:format.date(format: 'Y-m-d')}</time>, Published: <time>{blogPost.lastUpdated -> f:format.date(format: 'Y-m-d')}</time>,
Updated: <time>{blogPost.SYS_LASTCHANGED -> f:format.date(format: 'Y-m-d')}</time> Updated: <time>{blogPost.SYS_LASTCHANGED -> f:format.date(format: 'Y-m-d')}</time>
</p> </p>
<p>Tested with TYPO3:
{f:render(section: 'TopicList', arguments: { {f:render(section: 'TopicList', arguments: {
topics: compatibleWith, headline: 'Tested with TYPO3:',
addLinks: addLinks topics: compatibleWith,
})} addLinks: addLinks
</p> })}
<p>Topics:
{f:render(section: 'TopicList', arguments: { {f:render(section: 'TopicList', arguments: {
topics: topics, headline: 'Topics:',
addLinks: addLinks topics: topics,
})} addLinks: addLinks
</p> })}
</header> </header>
<f:section name="TopicList"> <f:section name="TopicList">
<f:for each="{topics}" as="topic" iteration="i"> <f:if condition="{topics}">
<f:render section="TopicLink" <p>{headline}
contentAs="content" <f:for each="{topics}" as="topic" iteration="i">
arguments="{ <f:render section="TopicLink"
addLinks: addLinks, contentAs="content"
topicUid: topic.data.uid arguments="{
}" addLinks: addLinks,
> topicUid: topic.data.uid
{topic.data.title}{f:if(condition: '!{i.isLast}', then: ',')} }"
</f:render> >
</f:for> {topic.data.title}{f:if(condition: '!{i.isLast}', then: ',')}
</f:render>
</f:for>
</p>
</f:if>
</f:section> </f:section>
<f:section name="TopicLink"> <f:section name="TopicLink">