Project DescriptionThis project allows authenticated users to rate documents, list items, issue items, calendar items. It follows the following rules
- Each AUTHENTICATED user can rate documents & items one or more times but only 1 vote per person will be kept for a given document/item. So, if a person has already voted, his/her current vote will replace the previous one.
- All the votes from all users for a given document/item allow the system to compute an average for that document
- The voting results are stored in a read-only custom field attached to a content type and represented by a five-stars picture. The number of votes is displayed when passing the mouse over the stars.
- A vote report is available to every authenticated user so that he can have a look at the current votes/coments for a given document/item
- A list manager can see a full report of all the votes done against a specific list
- A site owner can see a full report including all the votes of all the lists/doc libs for a given web site
- Standard SharePoint views can be applied on the doc lib to build views such as "top 5 rated documents etc..."
The project delivers 5 site collection content types that can be respectively associated to :
- Document libraries
- Issue lists
- Calendar lists
- Custom lists
- Link lists
To associate a content type to a list, you need to go to its advanced settings => allow management of content types. Then, back to the list settings, you click on add from existing site content types => pick up the CT corresponding to the current list
Once done, you'll have two new fields associated to your list "Voting Results" and "Voting Comments". They're both read-only custom fields.
"Voting Results" stores the vote average computed from all the votes.
"Voting Comments" is a link to the vote history
To see those fields, you need to check them in the default view associated to your list
You end-up with something like this:
You can vote either by clicking on "Vote" or on the stars, either on picking up the "Vote" action from the ECB
You'll be redirected to the voting page where you can pick up a rating value and leave a comment
Once done, you get the item rendered as follows:
Remember that only 1 vote per user is kept in the history. The number of stars will vary according to the vote average.
Now, if you click on "View Comments" or "View Vote Reports" from the ECB, you get the vote history for a given document/item
A list manager can view a full report on the list showing all the ratings for all the documents/items of the given list. You can see that by going to list settings

which shows you the list report
Eventually, a site owner can also visualize a report showing all the ratings for the entire web site

which shows this report
Using SharePoint Views You can use standard SharePoint views to encapsulate views such as "Top Rated Items", "Non-rated items" etc...just by applying filtering, sorting on the "Vote Results" column. Here are two examples
Top-Rated => create a view => descending sort on Vote Results
Non-Rated => create a view => filter (Vote Results Eq <leave it blank>)
Tips You can create a calculated column to get the number of votes for a given document/item so that you can perform sorts, filtering etc...using views
=IF([Vote Results]<>"",TRIM(MID([Vote Results],5,(FIND("vote(s)",[Vote Results])-5))),0)
and make sure you define your computed column as a number
When you've done that, you can for instance create a view "Most rated documents"
=> create a view => descending sort on you computed column
Scalability The system should be quite scalable because the vote history is stored within each rated item and not centrally. It means that the load is spread over the entire farm!
A few tests with a high number of votes (30 000 for only 1 doc) didn't reveal any performance trouble, instability...
Improvements Feel free to do whatever you want with that solution! A major improvement that could be done is localizing it. Indeed, the system has been designed in English.