I'm using Typo3 6.0 and News System 2.0. I have a custom template using fluid viewhelpers, and I'm displaying news from my database depending on their categories. So far so good, no problem.
My problem is that I want to loop through all the news records (which are in the table tx_news_domain_model_news) so I can use conditions to filter which ones are displayed, but so far it seems my attempts were in vain.
Why is it possible to loop through news categories like this :
<f:for each="{newsItem.categories}" as="category">
<f:if condition="{category.uid} == 9">
{category.title} #this is displayed correctly.
</f:if>
</f:for>
but when I try to loop through newsItem.uid, it's not working?
<f:for each="{newsItem.uid}" as="pub">
<f:if condition="{pub} == 5">
{pub.title}
</f:if>
</f:for>
Thank you for your time.