|
|
@ -67,6 +67,7 @@ class PollBankQuestionsController < ApplicationController
|
|
|
|
p_answer = params[:question_answers]
|
|
|
|
p_answer = params[:question_answers]
|
|
|
|
p_other_answer = params[:question_other_answer]
|
|
|
|
p_other_answer = params[:question_other_answer]
|
|
|
|
p_answer_count = p_answer.count
|
|
|
|
p_answer_count = p_answer.count
|
|
|
|
|
|
|
|
@poll_current_answers = @poll_question.exercise_bank_choices.count
|
|
|
|
@poll_question.exercise_bank_choices.each do |an|
|
|
|
|
@poll_question.exercise_bank_choices.each do |an|
|
|
|
|
if (p_answer_count < @poll_current_answers) && (p_answer_count..@poll_current_answers).to_a.include?(an.choice_position)
|
|
|
|
if (p_answer_count < @poll_current_answers) && (p_answer_count..@poll_current_answers).to_a.include?(an.choice_position)
|
|
|
|
an.destroy
|
|
|
|
an.destroy
|
|
|
|