dev_forum
SylorHuang 5 years ago
parent 533f5aee9e
commit 3b4e1e1516

@ -21,6 +21,7 @@ class PollsController < ApplicationController
# before_action :get_all_polls_commit, only: [:commit_result] #该问卷全部的用户
before_action :get_left_banner_id, only:[:common_header,:start_answer,:new,:edit,:index]
include PollsHelper
include ActionView::Helpers::TextHelper
def index
ActiveRecord::Base.transaction do
@ -911,7 +912,7 @@ class PollsController < ApplicationController
end
error_question = error_question.reject(&:blank?)
if error_question.reject(&:blank?).length > 0
normal_status(-1, "#{error_question.join("\n").gsub(/\n/, '<br>')}")
normal_status(-1, simple_format("#{error_question.join("\n")}"))
else
poll_user_current = @poll.poll_users.find_by_group_ids(current_user.id).first
poll_user_params = {

Loading…
Cancel
Save