From a6c61c8c2e21e803bceb77bce25d2b5705220be6 Mon Sep 17 00:00:00 2001 From: Jean-Philippe Lang Date: Sat, 7 Jan 2017 12:10:06 +0000 Subject: Preload :roles for displaying user memberships (#23519). git-svn-id: http://svn.redmine.org/redmine/trunk@16156 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- app/views/principal_memberships/_index.html.erb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'app/views/principal_memberships') diff --git a/app/views/principal_memberships/_index.html.erb b/app/views/principal_memberships/_index.html.erb index e43419072..508e2e271 100644 --- a/app/views/principal_memberships/_index.html.erb +++ b/app/views/principal_memberships/_index.html.erb @@ -1,4 +1,4 @@ -<% memberships = principal.memberships.preload(:member_roles => :role).sorted_by_project.to_a %> +<% memberships = principal.memberships.preload(:member_roles, :roles).sorted_by_project.to_a %>

<%= link_to l(:label_add_projects), new_principal_membership_path(principal), :remote => true, :class => "icon icon-add" %>

-- cgit v1.2.3