adds proposal votes

This commit is contained in:
rgarcia
2015-09-13 21:56:52 +02:00
parent d4b3e8be94
commit ad8880d02c
13 changed files with 311 additions and 26 deletions

View File

@@ -67,6 +67,11 @@ class ProposalsController < ApplicationController
respond_with @proposal, template: 'proposals/_refresh_flag_actions'
end
def vote
@proposal.register_vote(current_user, 'yes')
set_proposal_votes(@proposal)
end
private
def proposal_params