diff --git a/app/controllers/poll_controller.rb b/app/controllers/poll_controller.rb index 28c44f0cb..2e7d95478 100644 --- a/app/controllers/poll_controller.rb +++ b/app/controllers/poll_controller.rb @@ -90,7 +90,7 @@ class PollController < ApplicationController end end - #添加单选题 + #添加题目 def create_poll_question question_title = params[:poll_questions_title].nil? || params[:poll_questions_title].empty? ? l(:label_enter_single_title) : params[:poll_questions_title] option = { @@ -117,7 +117,7 @@ class PollController < ApplicationController end end - #修改单选题 + #修改题目 def update_poll_question @poll_question = PollQuestion.find params[:poll_question] #@poll = @poll_question.poll @@ -150,7 +150,7 @@ class PollController < ApplicationController end end - #删除单选题 + #删除题目 def delete_poll_question @poll_question = PollQuestion.find params[:poll_question] @poll = @poll_question.poll @@ -166,6 +166,11 @@ class PollController < ApplicationController end end + #发布问卷 + def publish_poll + + end + #提交答案 def commit_answer pq = PollQuestion.find(params[:poll_question_id]) diff --git a/config/routes.rb b/config/routes.rb index dc8205e2d..bd1b27dee 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -64,6 +64,7 @@ RedmineApp::Application.routes.draw do post 'commit_answer' post 'create_poll_question' post 'commit_poll' + get 'publish_poll' end collection do delete 'delete_poll_question'