As part of my summer of code project I have back-ported a new patch that got into Drupal HEAD which allows contributed modules to interact with the Drupal core search module's result ranking. I wrote an implementation of hook_ranking() for the fivestar module that makes nodes with higher average ratings float to the top of search results. The patch includes a new test file that provides simpletest coverage for the additions.

Requirements:
- Requires search_ranking module: http://drupal.org/project/search_ranking

Comments

cwgordon7’s picture

Subscribe. :)

quicksketch’s picture

Project: Fivestar » Voting API
Version: 6.x-1.12 » 6.x-2.0-beta6

Seems like this should belong in VotingAPI rather than Fivestar. Fivestar is simply a widget for registering votes; it doesn't deal with calculations or things that interact with the votingAPI tables.

BlakeLucchesi’s picture

FileSize
2.74 KB

Re-rolled for votingapi module. Passes simple test.

torotil’s picture

Version: 6.x-2.0-beta6 » 7.x-3.x-dev
Status: Needs review » Patch (to be ported)

This is pretty stale. The search_ranking module doesn't have a D7 version yet. Since active development is happening in 7.x-3.x now I won't commit this. Please reopen if there is a search_ranking version for D7 and a ported patch for the current version of votingapi.

torotil’s picture

Status: Patch (to be ported) » Closed (won't fix)