summaryrefslogtreecommitdiffstats
path: root/app/controllers/boards_controller.rb
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2016-04-18 17:51:10 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2016-04-18 17:51:10 +0000
commitfb6b565a1ec968a0f7f9f261ec1d6a328d891209 (patch)
treefb8d9d959c16bc77be493269408d7c50191f21ca /app/controllers/boards_controller.rb
parent42b5c332b2c24c8dcc2581e0cd130ef930959d99 (diff)
downloadredmine-fb6b565a1ec968a0f7f9f261ec1d6a328d891209.tar.gz
redmine-fb6b565a1ec968a0f7f9f261ec1d6a328d891209.zip
Forum list can be reordered with drag and drop (#12909).
git-svn-id: http://svn.redmine.org/redmine/trunk@15337 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/controllers/boards_controller.rb')
-rw-r--r--app/controllers/boards_controller.rb13
1 files changed, 11 insertions, 2 deletions
diff --git a/app/controllers/boards_controller.rb b/app/controllers/boards_controller.rb
index d56847131..9ab80f4f9 100644
--- a/app/controllers/boards_controller.rb
+++ b/app/controllers/boards_controller.rb
@@ -87,9 +87,18 @@ class BoardsController < ApplicationController
def update
@board.safe_attributes = params[:board]
if @board.save
- redirect_to_settings_in_projects
+ respond_to do |format|
+ format.html {
+ flash[:notice] = l(:notice_successful_update)
+ redirect_to_settings_in_projects
+ }
+ format.js { render :nothing => true }
+ end
else
- render :action => 'edit'
+ respond_to do |format|
+ format.html { render :action => 'edit' }
+ format.js { render :nothing => true, :status => 422 }
+ end
end
end