Commit 0f473674 authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Fix mr preload assoc

Signed-off-by: default avatarDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
parent ffce379a
...@@ -55,7 +55,7 @@ class DashboardController < ApplicationController ...@@ -55,7 +55,7 @@ class DashboardController < ApplicationController
def merge_requests def merge_requests
@merge_requests = FilteringService.new.execute(MergeRequest, current_user, params) @merge_requests = FilteringService.new.execute(MergeRequest, current_user, params)
@merge_requests = @merge_requests.page(params[:page]).per(20) @merge_requests = @merge_requests.page(params[:page]).per(20)
@merge_requests = @merge_requests.preload(:author, :project) @merge_requests = @merge_requests.preload(:author, :target_project)
end end
def issues def issues
......
...@@ -49,7 +49,7 @@ class GroupsController < ApplicationController ...@@ -49,7 +49,7 @@ class GroupsController < ApplicationController
def merge_requests def merge_requests
@merge_requests = FilteringService.new.execute(MergeRequest, current_user, params) @merge_requests = FilteringService.new.execute(MergeRequest, current_user, params)
@merge_requests = @merge_requests.page(params[:page]).per(20) @merge_requests = @merge_requests.page(params[:page]).per(20)
@merge_requests = @merge_requests.preload(:author, :project) @merge_requests = @merge_requests.preload(:author, :target_project)
end end
def issues def issues
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment