Closed (fixed)
Project:
Decisions
Version:
6.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
2 Apr 2010 at 15:53 UTC
Updated:
26 Apr 2010 at 18:00 UTC
Using Decisions - selection I create a test poll with 4 choices and max 2 allowed, I vote several times for choice 1 and 2 and one time for choise 1 and 3.
The result page shows:
choise 1 - 33% - 1 vote
choise 2 - 33% - 1 vote
choise 3 - 33% - 1 vote
choise 4 - 0% - 0 votes
Using the following modification in 'selection.module':
original line 252: $votes[$voteval]++;
modified line 252: $votes[$voteval]+=$result['value'];
it returns the correct results:
choise 1 - 50% - 5 votes
choise 2 - 40% - 4 votes
choise 3 - 10% - 1 vote
choise 4 - 0% - 0 votes
Comments
Comment #1
btmash commentedI was having the same issue, had the same exact patch I was going to propose. Seems like a winner to me.
Comment #2
Marat commentedThat works with me too, thank you.
Comment #3
Skirr commentedSave my day too. Thx.
Comment #4
ezra-g commentedI committed this with a coding standards correction. Thanks for the change! In the future, it would be great if you could roll a patch. http://drupal.org/project/patch Thanks!