The most efficient way would be database query with JOIN, GROUP BY and COUNT. Easier way is something like this: http://stackoverflow.com/questions/24208502/laravel-orderby-re...
/\ - Good article.
Sign in to participate in this thread!
We'd like to thank these amazing companies for supporting us
The Laravel portal for problem solving, knowledge sharing and community building.