fix frontend ask_category error

This commit is contained in:
thomaschen 2013-09-11 16:46:56 +08:00 committed by chris
parent 71dad22b04
commit b7bf180df2
2 changed files with 6 additions and 7 deletions

View File

@ -27,12 +27,11 @@ class Panel::Ask::BackEnd::AskRepliesController < OrbitBackendController
if @ask_reply.send_email?
Resque.enqueue(SendAskReplyMail, @ask_reply.ask_question.id)
end
##
binding.pry
params[:school][:depts].each do |dns|
send_request(dns, @ask_question, @ask_reply)
end unless params[:school].nil?
##
params[:school][:depts].each do |dns|
send_request(dns, @ask_question, @ask_reply)
end unless params[:school].nil?
redirect_to panel_ask_back_end_ask_questions_path, notice: t('ask.reply_success')
end

View File

@ -35,7 +35,7 @@ $(document).ready(function(){
<div class="control-group">
<%= f.label :ask_category_id, class: 'control-label required' %>
<div class="controls">
<%= f.collection_select :ask_category_id, AskCategory.all, :id, :name %>
<%= f.collection_select :ask_category_id, AskCategory.all.select { |c| c.key != 'transfered_question' }, :id, :name %>
</div>
</div>
<div class="control-group">