BigW Consortium Gitlab

_milestone.html.haml 1.41 KB
Newer Older
1
%li{class: "milestone milestone-#{milestone.closed? ? 'closed' : 'open'}", id: dom_id(milestone) }
2
  .pull-right
Andrew8xx8 committed
3
    - if can?(current_user, :admin_milestone, milestone.project) and milestone.active?
Dmitriy Zaporozhets committed
4
      = link_to edit_namespace_project_milestone_path(milestone.project.namespace, milestone.project, milestone), class: "btn btn-sm edit-milestone-link btn-grouped" do
5
        %i.fa.fa-pencil-square-o
6
        Edit
Dmitriy Zaporozhets committed
7
      = link_to 'Close Milestone', namespace_project_milestone_path(@project.namespace, @project, milestone, milestone: {state_event: :close }), method: :put, remote: true, class: "btn btn-sm btn-close"
8
  %h4
Vinnie Okada committed
9
    = link_to_gfm truncate(milestone.title, length: 100), namespace_project_milestone_path(milestone.project.namespace, milestone.project, milestone)
Andrew8xx8 committed
10
    - if milestone.expired? and not milestone.closed?
11
      %span.cred (Expired)
12 13
    %small
      = milestone.expires_at
14 15
  .row
    .col-sm-6
16
      = link_to namespace_project_issues_path(milestone.project.namespace, milestone.project, milestone_title: milestone.title) do
17 18
        = pluralize milestone.issues.count, 'Issue'
       
19
      = link_to namespace_project_merge_requests_path(milestone.project.namespace, milestone.project, milestone_title: milestone.title) do
20 21 22 23
        = pluralize milestone.merge_requests.count, 'Merge Request'
       
      %span.light #{milestone.percent_complete}% complete
    .col-sm-6
24
      = milestone_progress_bar(milestone)