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
c85c6815
Commit
c85c6815
authored
Dec 15, 2016
by
Berna Castro
Committed by
Oswaldo Ferreira
Jan 27, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add the group path to the issue ID if applicable
parent
4e2b9d70
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
5 deletions
+13
-5
app/models/project.rb
app/models/project.rb
+12
-4
app/views/projects/issues/_issue.html.haml
app/views/projects/issues/_issue.html.haml
+1
-1
No files found.
app/models/project.rb
View file @
c85c6815
...
@@ -591,11 +591,19 @@ class Project < ActiveRecord::Base
...
@@ -591,11 +591,19 @@ class Project < ActiveRecord::Base
end
end
end
end
def
to_reference
(
from_project
=
nil
,
full:
false
)
def
to_reference
(
from_project
=
nil
,
from_group
=
nil
)
if
full
||
cross_namespace_reference?
(
from_project
)
if
from_group
.
nil?
if
cross_namespace_reference?
(
from_project
)
path_with_namespace
path_with_namespace
elsif
cross_project_reference?
(
from_project
)
elsif
cross_project_reference?
(
from_project
)
path
path
elsif
self
==
from_project
nil
else
path_with_namespace
end
else
path
end
end
end
end
...
...
app/views/projects/issues/_issue.html.haml
View file @
c85c6815
...
@@ -34,7 +34,7 @@
...
@@ -34,7 +34,7 @@
=
note_count
=
note_count
.issue-info
.issue-info
#{
issue
.
to_reference
}
·
#{
issue
.
to_reference
(
@project
,
@group
)
}
·
opened
#{
time_ago_with_tooltip
(
issue
.
created_at
,
placement:
'bottom'
)
}
opened
#{
time_ago_with_tooltip
(
issue
.
created_at
,
placement:
'bottom'
)
}
by
#{
link_to_member
(
@project
,
issue
.
author
,
avatar:
false
)
}
by
#{
link_to_member
(
@project
,
issue
.
author
,
avatar:
false
)
}
-
if
issue
.
milestone
-
if
issue
.
milestone
...
...
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