gitlab-org--gitlab-foss/app/views/milestones/_milestone.html.haml

29 lines
1.3 KiB
Text
Raw Normal View History

2013-02-18 04:10:09 -05:00
%li{class: "milestone milestone-#{milestone.closed? ? 'closed' : 'open'}", id: dom_id(milestone) }
2013-01-30 09:40:43 -05:00
.pull-right
2013-02-18 05:43:08 -05:00
- if can?(current_user, :admin_milestone, milestone.project) and milestone.active?
2013-01-29 15:29:21 -05:00
= link_to edit_project_milestone_path(milestone.project, milestone), class: "btn btn-small edit-milestone-link grouped" do
%i.icon-edit
Edit
- if milestone.can_be_closed?
= link_to 'Close', project_milestone_path(@project, milestone, milestone: {state_event: :close }), method: :put, remote: true, class: "btn btn-small btn-remove"
2012-07-22 08:37:46 -04:00
%h4
= link_to_gfm truncate(milestone.title, length: 100), project_milestone_path(milestone.project, milestone)
2013-02-18 07:49:56 -05:00
- if milestone.expired? and not milestone.closed?
2012-12-14 00:34:05 -05:00
%span.cred (Expired)
2012-07-22 08:37:46 -04:00
%small
= milestone.expires_at
2012-12-18 22:14:05 -05:00
- if milestone.is_empty?
%span.muted Empty
- else
2013-04-16 13:01:21 -04:00
%div
%div
2012-12-18 22:14:05 -05:00
= link_to project_issues_path(milestone.project, milestone_id: milestone.id) do
= pluralize milestone.issues.count, 'Issue'
 
= link_to project_merge_requests_path(milestone.project, milestone_id: milestone.id) do
= pluralize milestone.merge_requests.count, 'Merge Request'
 
%span.light #{milestone.percent_complete}% complete
2013-04-16 13:01:21 -04:00
.progress.progress-info
.bar{style: "width: #{milestone.percent_complete}%;"}