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
0
Merge Requests
0
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
Jérome Perrin
gitlab-ce
Commits
2bacc040
Commit
2bacc040
authored
Mar 24, 2017
by
Mike Greiling
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
move links to browse issuables into sidebar
parent
470bba5c
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
41 additions
and
48 deletions
+41
-48
app/assets/stylesheets/pages/milestone.scss
app/assets/stylesheets/pages/milestone.scss
+0
-20
app/helpers/milestones_helper.rb
app/helpers/milestones_helper.rb
+2
-2
app/views/shared/milestones/_sidebar.html.haml
app/views/shared/milestones/_sidebar.html.haml
+39
-15
app/views/shared/milestones/_summary.html.haml
app/views/shared/milestones/_summary.html.haml
+0
-11
No files found.
app/assets/stylesheets/pages/milestone.scss
View file @
2bacc040
...
@@ -73,26 +73,6 @@
...
@@ -73,26 +73,6 @@
}
}
}
}
.milestone-progress-buttons
{
order
:
1
;
margin-top
:
10px
;
@media
(
min-width
:
$screen-xs-min
)
{
order
:
2
;
margin-top
:
0
;
flex-shrink
:
0
;
}
.btn
{
float
:
left
;
margin-right
:
$btn-side-margin
;
&
:last-child
{
margin-right
:
0
;
}
}
}
.milestone-stats
{
.milestone-stats
{
order
:
2
;
order
:
2
;
width
:
100%
;
width
:
100%
;
...
...
app/helpers/milestones_helper.rb
View file @
2bacc040
...
@@ -19,8 +19,8 @@ module MilestonesHelper
...
@@ -19,8 +19,8 @@ module MilestonesHelper
end
end
end
end
def
milestones_browse_issuables_path
(
milestone
,
type
:)
def
milestones_browse_issuables_path
(
milestone
,
state:
nil
,
type
:)
opts
=
{
milestone_title:
milestone
.
title
}
opts
=
{
milestone_title:
milestone
.
title
,
state:
state
}
if
@project
if
@project
polymorphic_path
([
@project
.
namespace
.
becomes
(
Namespace
),
@project
,
type
],
opts
)
polymorphic_path
([
@project
.
namespace
.
becomes
(
Namespace
),
@project
,
type
],
opts
)
...
...
app/views/shared/milestones/_sidebar.html.haml
View file @
2bacc040
...
@@ -44,6 +44,16 @@
...
@@ -44,6 +44,16 @@
=
link_to
new_namespace_project_issue_path
(
project
.
namespace
,
project
,
issue:
{
milestone_id:
milestone
.
id
}),
class:
"pull-right"
,
title:
"New Issue"
do
=
link_to
new_namespace_project_issue_path
(
project
.
namespace
,
project
,
issue:
{
milestone_id:
milestone
.
id
}),
class:
"pull-right"
,
title:
"New Issue"
do
New issue
New issue
.value.hide-collapsed
.value.hide-collapsed
-
if
project
&&
can?
(
current_user
,
:read_issue
,
project
)
%span
.milestone-stat
=
link_to
milestones_browse_issuables_path
(
milestone
,
type: :issues
)
do
Open:
=
milestone
.
issues_visible_to_user
(
current_user
).
opened
.
size
%span
.milestone-stat
=
link_to
milestones_browse_issuables_path
(
milestone
,
type: :issues
,
state:
'closed'
)
do
Closed:
=
milestone
.
issues_visible_to_user
(
current_user
).
closed
.
size
-
else
%span
.milestone-stat
%span
.milestone-stat
Open:
Open:
=
milestone
.
issues_visible_to_user
(
current_user
).
opened
.
size
=
milestone
.
issues_visible_to_user
(
current_user
).
opened
.
size
...
@@ -60,6 +70,20 @@
...
@@ -60,6 +70,20 @@
Merge requests
Merge requests
%span
.badge
=
milestone
.
merge_requests
.
size
%span
.badge
=
milestone
.
merge_requests
.
size
.value.hide-collapsed
.value.hide-collapsed
-
if
project
&&
can?
(
current_user
,
:read_merge_request
,
project
)
%span
.milestone-stat
=
link_to
milestones_browse_issuables_path
(
milestone
,
type: :merge_requests
)
do
Open:
=
milestone
.
merge_requests
.
opened
.
size
%span
.milestone-stat
=
link_to
milestones_browse_issuables_path
(
milestone
,
type: :merge_requests
,
state:
'closed'
)
do
Closed:
=
milestone
.
merge_requests
.
closed
.
size
%span
.milestone-stat
=
link_to
milestones_browse_issuables_path
(
milestone
,
type: :merge_requests
,
state:
'merged'
)
do
Merged:
=
milestone
.
merge_requests
.
merged
.
size
-
else
%span
.milestone-stat
%span
.milestone-stat
Open:
Open:
=
milestone
.
merge_requests
.
opened
.
size
=
milestone
.
merge_requests
.
opened
.
size
...
...
app/views/shared/milestones/_summary.html.haml
View file @
2bacc040
...
@@ -10,15 +10,4 @@
...
@@ -10,15 +10,4 @@
%strong
==
#{
milestone
.
percent_complete
(
current_user
)
}
%
%strong
==
#{
milestone
.
percent_complete
(
current_user
)
}
%
complete
complete
.milestone-progress-buttons
%span
.tab-issues-buttons
-
if
project
-
if
can?
(
current_user
,
:create_issue
,
project
)
=
link_to
new_namespace_project_issue_path
(
project
.
namespace
,
project
,
issue:
{
milestone_id:
milestone
.
id
}),
class:
"btn"
,
title:
"New Issue"
do
New Issue
-
if
can?
(
current_user
,
:read_issue
,
project
)
=
link_to
'Browse Issues'
,
milestones_browse_issuables_path
(
milestone
,
type: :issues
),
class:
"btn"
%span
.tab-merge-requests-buttons.hidden
=
link_to
'Browse Merge Requests'
,
milestones_browse_issuables_path
(
milestone
,
type: :merge_requests
),
class:
"btn"
=
milestone_progress_bar
(
milestone
)
=
milestone_progress_bar
(
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