Commit ace81635 authored by Robert Speicher's avatar Robert Speicher

Add toggle to show closed issues on Milestones#show

Progress on #1167
parent 2b7fd29b
$ ->
$('.milestone-issue-filter td[data-closed]').addClass('hide')
$('.milestone-issue-filter ul.nav li a').click ->
$('.milestone-issue-filter li').toggleClass('active')
$('.milestone-issue-filter td[data-closed]').toggleClass('hide')
false
...@@ -11,6 +11,11 @@ table { ...@@ -11,6 +11,11 @@ table {
border-bottom: 1px solid #bbb; border-bottom: 1px solid #bbb;
text-shadow: 0 1px 1px #fff; text-shadow: 0 1px 1px #fff;
@include bg-dark-gray-gradient; @include bg-dark-gray-gradient;
ul.nav {
text-shadow: none;
margin: 0;
}
} }
th, td { th, td {
......
...@@ -30,7 +30,7 @@ class MilestonesController < ProjectResourceController ...@@ -30,7 +30,7 @@ class MilestonesController < ProjectResourceController
end end
def show def show
@issues = @milestone.issues.opened.page(params[:page]).per(40) @issues = @milestone.issues
@users = @milestone.participants @users = @milestone.participants
respond_to do |format| respond_to do |format|
......
...@@ -45,18 +45,20 @@ ...@@ -45,18 +45,20 @@
.row .row
.span6 .span6
%table %table.milestone-issue-filter
%thead %thead
%th Open Issues %th
%ul.nav.nav-pills
%li.active.open= link_to('Open Issues', '#')
%li.all=link_to('All Issues', '#')
- @issues.each do |issue| - @issues.each do |issue|
%tr %tr
%td %td{data: {closed: issue.closed}}
= link_to [@project, issue] do = link_to [@project, issue] do
%span.badge.badge-info ##{issue.id} %span.badge.badge-info ##{issue.id}
&ndash; &ndash;
= link_to_gfm truncate(issue.title, length: 60), [@project, issue] = link_to_gfm truncate(issue.title, length: 60), [@project, issue]
%br %br
= paginate @issues, theme: "gitlab"
.span6 .span6
%table %table
......
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