Project

General

Profile

Patch #10582 » hook_controller_projects_new_after_save-r9299.patch

Patch add a hook for controller_projects_new_after_save - Sajin Andrei, 2012-04-02 11:26

View differences:

app/controllers/projects_controller.rb (working copy)
@project.safe_attributes = params[:project]
if validate_parent_id && @project.save
call_hook(:controller_projects_new_after_save, { :params => params, :project => @project})
@project.set_allowed_parent!(params[:project]['parent_id']) if params[:project].has_key?('parent_id')
# Add current user as a project member if he is not admin
unless User.current.admin?
(1-1/2)