X-Git-Url: https://projects.mako.cc/source/selectricity/blobdiff_plain/91c9d10ebdbdd37b03fd287a9923759f85561d20..e2d5b6e7b4f5ed6fb0cbec01df80bd50a6796950:/app/controllers/voter_controller.rb diff --git a/app/controllers/voter_controller.rb b/app/controllers/voter_controller.rb index 9e88e9e..45b9a1a 100644 --- a/app/controllers/voter_controller.rb +++ b/app/controllers/voter_controller.rb @@ -17,6 +17,7 @@ # . class VoterController < ApplicationController + helper :sparklines layout 'main' require_dependency "voter" require_dependency "vote" @@ -106,8 +107,8 @@ class VoterController < ApplicationController def details if authenticate @election = @voter.election - @votes = @election.votes.select {|v| v.confirmed? }.randomize - @voters = @votes.collect {|v| v.voter}.randomize + @votes = @election.votes.select {|v| v.confirmed? }.shuffle + @voters = @votes.collect {|v| v.voter}.shuffle render :action => 'details' else redirect_to :action => 'index'