Do not show inactive document categories where not necessary (#8573).

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@6071 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Baptiste Barth
2011-06-13 20:33:06 +00:00
parent d5cc7424a8
commit ffe7aef0ea
4 changed files with 11 additions and 2 deletions

View File

@@ -57,7 +57,7 @@ class DocumentsController < ApplicationController
end
def edit
@categories = DocumentCategory.all
@categories = DocumentCategory.active #TODO: use it in the views
if request.post? and @document.update_attributes(params[:document])
flash[:notice] = l(:notice_successful_update)
redirect_to :action => 'show', :id => @document