I'm trying to create a list of the 10 most liked 'Freestyles' on my website.
The like table has the freestyle ID and a user ID inside of it, the freestyle belongs to the like table.
I'm wondering how I can express this in eloquent and retrieve the SUM of all of the likes in the Like table via the Freestyle ID.
So, where all of the freestyle IDs = 1 (for example) count them and return the amount.
Sorry if it doesn't make much sense!