Refactor: convert ProjectEnumerations to a resource on a project.

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@4075 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Eric Davis
2010-09-10 16:00:49 +00:00
parent 5e1c295230
commit 3a2efb4757
7 changed files with 29 additions and 26 deletions
@@ -169,6 +169,13 @@ class ApplicationController < ActionController::Base
render_404
end
# Find project of id params[:project_id]
def find_project_by_project_id
@project = Project.find(params[:project_id])
rescue ActiveRecord::RecordNotFound
render_404
end
# Find a project based on params[:project_id]
# TODO: some subclasses override this, see about merging their logic
def find_optional_project