- Bronze Partner | 189
a have tables
Users M:N connected by
article_like. It says, who liked an article. Also there is
Tag, M:N again, connected to articles table.
In the template linked below, I have a
tag. By this tag, a list
of articles is listed. It works well in this state. But I would like to have
this list sorted by count of likes.
How can I achieve that? Is it even possible? I think I was close with
->order('COUNT(article(article_like):users.id)'), but the error
No reference found for $article->related(users). says this is
You can find Czech version here https://forum.nette.org/…jene-tabulky#…
Last edited by medhi (2015-01-26 17:50)