gitlab-org--gitlab-foss/app/views/projects/issues/_issue.html.haml

62 lines
2 KiB
Text
Raw Normal View History

%li{ id: dom_id(issue), class: issue_css_classes(issue), url: issue_path(issue) }
- if controller.controller_name == 'issues' && can?(current_user, :admin_issue, @project)
2013-04-06 08:10:24 -04:00
.issue-check
= check_box_tag dom_id(issue,"selected"), nil, false, 'data-id' => issue.id, class: "selected_issue"
2013-04-06 08:10:24 -04:00
.issue-title.title
2015-07-22 10:53:18 -04:00
%span.issue-title-text
= confidential_icon(issue)
= link_to_gfm issue.title, issue_path(issue)
%ul.controls
2015-07-22 10:53:18 -04:00
- if issue.closed?
%li
2015-07-22 10:53:18 -04:00
CLOSED
2015-07-22 10:53:18 -04:00
- if issue.assignee
%li
= link_to_member(@project, issue.assignee, name: false, title: "Assigned to :name")
- upvotes, downvotes = issue.upvotes, issue.downvotes
- if upvotes > 0
%li
= icon('thumbs-up')
= upvotes
- if downvotes > 0
%li
= icon('thumbs-down')
= downvotes
- note_count = issue.notes.user.nonawards.count
2015-07-22 10:53:18 -04:00
- if note_count > 0
%li
= link_to issue_path(issue) + "#notes" do
= icon('comments')
= note_count
2015-07-22 10:53:18 -04:00
- else
%li
= link_to issue_path(issue) + "#notes", class: "issue-no-comments" do
= icon('comments')
2015-12-08 16:39:26 -05:00
= note_count
2015-07-22 10:53:18 -04:00
.issue-info
#{issue.to_reference} ·
opened #{time_ago_with_tooltip(issue.created_at, placement: 'bottom')}
by #{link_to_member(@project, issue.author, avatar: false)}
2015-07-22 10:53:18 -04:00
- if issue.milestone
 
= link_to namespace_project_issues_path(issue.project.namespace, issue.project, milestone_title: issue.milestone.title) do
= icon('clock-o')
2015-07-22 10:53:18 -04:00
= issue.milestone.title
- if issue.labels.any?
 
- issue.labels.each do |label|
= link_to_label(label, project: issue.project)
2015-07-22 10:53:18 -04:00
- if issue.tasks?
 
2015-07-22 10:53:18 -04:00
%span.task-status
= issue.task_status
2015-07-22 10:53:18 -04:00
.pull-right.issue-updated-at
%span updated #{time_ago_with_tooltip(issue.updated_at, placement: 'bottom', html_class: 'issue_update_ago')}