From 4666ddb10e1061ca3ef362735d0d264676b99024 Mon Sep 17 00:00:00 2001 From: Eric Davis Date: Thu, 5 Feb 2009 17:05:59 -0800 Subject: [PATCH] Fixed two bugs caused by the core changes to project/subprojects. Might break compatibility with the 0.8.x branch of Redmine. #2089 --- app/views/rates/_form.html.erb | 2 +- app/views/users/_memberships.rhtml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/views/rates/_form.html.erb b/app/views/rates/_form.html.erb index f5c36e8..b068a13 100644 --- a/app/views/rates/_form.html.erb +++ b/app/views/rates/_form.html.erb @@ -13,7 +13,7 @@ <%= # TODO: move to controller once a hook is in place for the Admin panel - projects = Project.find(:all, :conditions => { :status => Project::STATUS_ACTIVE}, :include => :parent) + projects = Project.find(:all, :conditions => { :status => Project::STATUS_ACTIVE}) select_tag("rate[project_id]", project_options_for_select_with_selected(projects, @rate.project)) %> diff --git a/app/views/users/_memberships.rhtml b/app/views/users/_memberships.rhtml index d01b3c9..bd6d7d0 100644 --- a/app/views/users/_memberships.rhtml +++ b/app/views/users/_memberships.rhtml @@ -58,7 +58,7 @@


<% form_tag({ :action => 'edit_membership', :id => @user }) do %> -<%= select_tag 'membership[project_id]', projects_options_for_select(@projects) %> +<%= select_tag 'membership[project_id]', options_for_membership_project_select(@user, @projects) %> <%= l(:label_role) %>: <%= select_tag 'membership[role_id]', options_from_collection_for_select(@roles, "id", "name") %> <%= submit_tag l(:button_add) %>