Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
a2f57f23
Commit
a2f57f23
authored
Dec 19, 2016
by
James Edwards-Jones
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix N+1 queries on milestone show pages
parent
01adeb17
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
1 deletion
+7
-1
app/models/issue.rb
app/models/issue.rb
+2
-0
app/views/shared/milestones/_tabs.html.haml
app/views/shared/milestones/_tabs.html.haml
+1
-1
changelogs/unreleased/jej-fix-n-1-queries-milestones-show.yml
...gelogs/unreleased/jej-fix-n-1-queries-milestones-show.yml
+4
-0
No files found.
app/models/issue.rb
View file @
a2f57f23
...
...
@@ -39,6 +39,8 @@ class Issue < ActiveRecord::Base
scope
:created_after
,
->
(
datetime
)
{
where
(
"created_at >= ?"
,
datetime
)
}
scope
:include_associations
,
->
{
includes
(
:assignee
,
:labels
,
project: :namespace
)
}
attr_spammable
:title
,
spam_title:
true
attr_spammable
:description
,
spam_description:
true
...
...
app/views/shared/milestones/_tabs.html.haml
View file @
a2f57f23
...
...
@@ -21,7 +21,7 @@
.tab-content.milestone-content
.tab-pane.active
#tab-issues
=
render
'shared/milestones/issues_tab'
,
issues:
milestone
.
issues_visible_to_user
(
current_user
),
show_project_name:
show_project_name
,
show_full_project_name:
show_full_project_name
=
render
'shared/milestones/issues_tab'
,
issues:
milestone
.
issues_visible_to_user
(
current_user
)
.
include_associations
,
show_project_name:
show_project_name
,
show_full_project_name:
show_full_project_name
.tab-pane
#tab-merge-requests
=
render
'shared/milestones/merge_requests_tab'
,
merge_requests:
milestone
.
merge_requests
,
show_project_name:
show_project_name
,
show_full_project_name:
show_full_project_name
.tab-pane
#tab-participants
...
...
changelogs/unreleased/jej-fix-n-1-queries-milestones-show.yml
0 → 100644
View file @
a2f57f23
---
title
:
Fix N+1 queries on milestone show pages
merge_request
:
8185
author
:
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment