I have 2 tables: news and comments.
news has many comments and comment belongs to article
On the show action I want to show all the comments that
belong to a news item, excluding the ones that are not approved yet.
It’s the excluding part that’s causing me problems.
example sql (from the head, not tested):
select news.id,news.title,news.article,comments.message, …
where comments.news_id = news.id
AND approved = 1
How do I set this up in the models ?