|
|
|
@ -91,6 +91,7 @@ class PollVotesController < ApplicationController
|
|
|
|
|
end
|
|
|
|
|
else #主观题的输入
|
|
|
|
|
# current_vote_text = user_votes.find_vote_text
|
|
|
|
|
if question_answer_text.present?
|
|
|
|
|
if user_votes.present?
|
|
|
|
|
user_votes.first.update_attribute("vote_text", question_answer_text)
|
|
|
|
|
# if question_answer_text.present?
|
|
|
|
@ -102,6 +103,7 @@ class PollVotesController < ApplicationController
|
|
|
|
|
PollVote.create(vote_answer_params)
|
|
|
|
|
end
|
|
|
|
|
end
|
|
|
|
|
end
|
|
|
|
|
@current_question_number = @poll_question.question_number
|
|
|
|
|
@current_question_necessary = @poll_question.is_necessary
|
|
|
|
|
#问答记录存在,且有值,才会有返回值。
|
|
|
|
|