Jump to content

Sort by "Overall Rating" is broken in 6.2.1


Recommended Posts

I have noticed a bug where if I set a videos list block to sort by "Overall Rating" it will simply sort by the video IDs. Sorting by "Rating Today", "Rating this week", and "Rating this month" seems to work correctly. But since "Overall Rating" doesn't work this also causes the "Top Rated" sort option under the categories video lists to not work and to simply sort by the video IDs. Is there anything I can do on my end to fix this, or is the issue within the encoded php?

 

Also what value does it sort by when using sorting by "Rating this month" for example? Is it sorting using $item.rating, or $item.rating_amount, or is it using the $item.rating/5*100 calculation output? 

From my tests it seems like its only using  $item.rating_amount to sort. Because of that I have noticed if a video for example has 0 likes, and 5 dislikes, it will rank higher than a video with 4 likes and 0 dislikes since the heavily disliked video has a total of 5 votes while the better rated video will only have 4 votes which creates a flawed sorting.

Would it be possible to have the "Overall Rating" sorting based on the $final_output from this calculation? This would allow videos to be sorted by their overall score, which would allow videos with a lot of dislikes to rank lower than a video with no votes at all.

{{assign var="likes" value=0}}
{{assign var="dislikes" value=0}}
{{if $item.rating>0}}
  {{assign var="likes" value=$item.rating*$item.rating_amount/5|replace:",":"."|floor}}
  {{assign var="dislikes" value=$item.rating_amount-$likes}}
{{/if}}

{{assign var="final_score" value=$likes-$dislikes}}

 

Is it possible for me to simply created my own sorting methods without source code access? I have noticed "Custom 1", Custom 2", and "Custom 3" exist as sorting methods and they all do the same thing. How can I edit the sorting calculations for those custom sorting methods that are available?

 

I am using KVS version 6.2.1.

Thanks!

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...