From 2a2b93c97df190329af0e710ab0f3dea2d59d304 Mon Sep 17 00:00:00 2001 From: sw <939547590@qq.com> Date: Fri, 12 Jun 2015 16:58:43 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AF=BC=E5=87=BA=E9=97=AE=E5=8D=B7=E6=97=B6?= =?UTF-8?q?=EF=BC=8C=E5=A4=9A=E8=A1=8C=E4=B8=BB=E8=A7=82=E7=9A=84=E7=AD=94?= =?UTF-8?q?=E6=A1=88=E6=9C=89html=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/poll_controller.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/controllers/poll_controller.rb b/app/controllers/poll_controller.rb index 73650a782..a222314ab 100644 --- a/app/controllers/poll_controller.rb +++ b/app/controllers/poll_controller.rb @@ -464,7 +464,7 @@ class PollController < ApplicationController sheet1[count_row + 1,0] = l(:label_poll_subtotal) sheet1[count_row + 2,0] = l(:label_poll_proportion) poll_question.poll_answers.each_with_index do |poll_answer,i| - sheet1[count_row, i + 1] = poll_answer.answer_text + sheet1[count_row, i + 1] = poll_answer.answer_text.gsub(/<\/?.*?>/,"").gsub(/ /," ") sheet1[count_row + 1, i + 1] = poll_answer.poll_votes.count sheet1[count_row + 2, i + 1] = statistics_result_percentage(poll_answer.poll_votes.count, total_answer(poll_question.id)).to_s + "%" end @@ -477,7 +477,7 @@ class PollController < ApplicationController sheet1[count_row,1] = poll_question.question_title count_row += 1 poll_question.poll_votes.each do |poll_vote| - sheet1[count_row,0] = poll_vote.vote_text + sheet1[count_row,0] = poll_vote.vote_text.gsub(/<\/?.*?>/,"").gsub(/ /," ") count_row += 1 end count_row += 1