2017-01-05 21:07:13 +00:00
|
|
|
- @content_class = "limit-container-width" unless fluid_layout
|
2017-08-16 09:35:59 +00:00
|
|
|
- breadcrumb_title "Issues #{@issue.to_reference}"
|
2016-10-19 10:23:51 +00:00
|
|
|
- page_title "#{@issue.title} (#{@issue.to_reference})", "Issues"
|
2015-12-24 22:03:54 +00:00
|
|
|
- page_description @issue.description
|
|
|
|
- page_card_attributes @issue.card_attributes
|
2017-05-24 10:00:27 +00:00
|
|
|
- can_update_issue = can?(current_user, :update_issue, @issue)
|
|
|
|
- can_report_spam = @issue.submittable_as_spam_by?(current_user)
|
2015-12-23 21:56:27 +00:00
|
|
|
|
2016-04-01 10:55:26 +00:00
|
|
|
.clearfix.detail-page-header
|
|
|
|
.issuable-header
|
2016-04-12 15:27:16 +00:00
|
|
|
.issuable-status-box.status-box.status-box-closed{ class: issue_button_visibility(@issue, false) }
|
2016-04-01 10:55:26 +00:00
|
|
|
= icon('check', class: "hidden-sm hidden-md hidden-lg")
|
|
|
|
%span.hidden-xs
|
|
|
|
Closed
|
2016-04-12 15:27:16 +00:00
|
|
|
.issuable-status-box.status-box.status-box-open{ class: issue_button_visibility(@issue, true) }
|
2016-04-01 10:55:26 +00:00
|
|
|
= icon('circle-o', class: "hidden-sm hidden-md hidden-lg")
|
|
|
|
%span.hidden-xs Open
|
2015-09-17 10:16:24 +00:00
|
|
|
|
2016-04-01 10:55:26 +00:00
|
|
|
%a.btn.btn-default.pull-right.visible-xs-block.gutter-toggle.issuable-gutter-toggle.js-sidebar-toggle{ href: "#" }
|
2016-03-04 18:24:24 +00:00
|
|
|
= icon('angle-double-left')
|
2016-02-29 23:04:40 +00:00
|
|
|
|
2016-04-01 10:55:26 +00:00
|
|
|
.issuable-meta
|
2017-08-07 23:56:16 +00:00
|
|
|
- if @issue.confidential
|
|
|
|
= icon('eye-slash', class: 'is-confidential')
|
2016-04-01 11:20:54 +00:00
|
|
|
= issuable_meta(@issue, @project, "Issue")
|
2016-02-29 20:13:00 +00:00
|
|
|
|
2017-03-06 20:18:39 +00:00
|
|
|
.issuable-actions
|
|
|
|
.clearfix.issue-btn-group.dropdown
|
|
|
|
%button.btn.btn-default.pull-left.hidden-md.hidden-lg{ type: "button", data: { toggle: "dropdown" } }
|
|
|
|
Options
|
|
|
|
= icon('caret-down')
|
|
|
|
.dropdown-menu.dropdown-menu-align-right.hidden-lg
|
|
|
|
%ul
|
2017-05-24 10:00:27 +00:00
|
|
|
- if can_update_issue
|
2017-06-07 16:42:09 +00:00
|
|
|
%li= link_to 'Edit', edit_project_issue_path(@project, @issue)
|
2017-07-03 16:00:59 +00:00
|
|
|
- unless current_user == @issue.author
|
|
|
|
%li= link_to 'Report abuse', new_abuse_report_path(user_id: @issue.author.id, ref_url: issue_url(@issue))
|
2017-06-07 16:42:09 +00:00
|
|
|
- if can_update_issue
|
|
|
|
%li= link_to 'Close issue', issue_path(@issue, issue: { state_event: :close }, format: 'json'), class: "btn-close #{issue_button_visibility(@issue, true)}", title: 'Close issue'
|
|
|
|
%li= link_to 'Reopen issue', issue_path(@issue, issue: { state_event: :reopen }, format: 'json'), class: "btn-reopen #{issue_button_visibility(@issue, false)}", title: 'Reopen issue'
|
2017-05-24 10:00:27 +00:00
|
|
|
- if can_report_spam
|
2017-06-07 16:42:09 +00:00
|
|
|
%li= link_to 'Submit as spam', mark_as_spam_project_issue_path(@project, @issue), method: :post, class: 'btn-spam', title: 'Submit as spam'
|
2017-05-24 10:00:27 +00:00
|
|
|
- if can_update_issue || can_report_spam
|
|
|
|
%li.divider
|
2017-06-07 16:42:09 +00:00
|
|
|
%li= link_to 'New issue', new_project_issue_path(@project), title: 'New issue', id: 'new_issue_link'
|
2017-03-06 20:18:39 +00:00
|
|
|
|
2017-05-24 10:00:27 +00:00
|
|
|
- if can_update_issue
|
2017-06-29 17:06:35 +00:00
|
|
|
= link_to 'Edit', edit_project_issue_path(@project, @issue), class: 'hidden-xs hidden-sm btn btn-grouped issuable-edit'
|
2017-06-07 10:18:35 +00:00
|
|
|
|
|
|
|
= render 'shared/issuable/close_reopen_button', issuable: @issue, can_update: can_update_issue
|
|
|
|
|
2017-05-24 10:00:27 +00:00
|
|
|
- if can_report_spam
|
2017-06-29 17:06:35 +00:00
|
|
|
= link_to 'Submit as spam', mark_as_spam_project_issue_path(@project, @issue), method: :post, class: 'hidden-xs hidden-sm btn btn-grouped btn-spam', title: 'Submit as spam'
|
|
|
|
= link_to new_project_issue_path(@project), class: 'hidden-xs hidden-sm btn btn-grouped new-issue-link btn-new btn-inverted', title: 'New issue', id: 'new_issue_link' do
|
2017-03-06 20:18:39 +00:00
|
|
|
New issue
|
2013-12-19 17:36:27 +00:00
|
|
|
|
2016-04-01 10:55:26 +00:00
|
|
|
.issue-details.issuable-details
|
2017-04-25 17:13:59 +00:00
|
|
|
.detail-page-description.content-block
|
2017-05-15 13:51:40 +00:00
|
|
|
%script#js-issuable-app-initial-data{ type: "application/json" }= issuable_initial_data(@issue)
|
2017-05-24 11:25:53 +00:00
|
|
|
#js-issuable-app
|
2017-05-10 11:29:33 +00:00
|
|
|
%h2.title= markdown_field(@issue, :title)
|
|
|
|
- if @issue.description.present?
|
|
|
|
.description{ class: can?(current_user, :update_issue, @issue) ? 'js-task-list-container' : '' }
|
|
|
|
.wiki= markdown_field(@issue, :description)
|
|
|
|
%textarea.hidden.js-task-list-field= @issue.description
|
2017-04-21 20:34:11 +00:00
|
|
|
|
2017-05-18 12:24:34 +00:00
|
|
|
= edited_time_ago_with_tooltip(@issue, placement: 'bottom', html_class: 'issue-edited-ago js-issue-edited-ago')
|
2015-12-17 09:34:15 +00:00
|
|
|
|
2017-06-29 17:06:35 +00:00
|
|
|
#merge-requests{ data: { url: referenced_merge_requests_project_issue_url(@project, @issue) } }
|
2016-04-14 09:14:12 +00:00
|
|
|
// This element is filled in using JavaScript.
|
2016-04-12 13:55:54 +00:00
|
|
|
|
2017-06-29 17:06:35 +00:00
|
|
|
#related-branches{ data: { url: related_branches_project_issue_url(@project, @issue) } }
|
2016-04-14 09:14:12 +00:00
|
|
|
// This element is filled in using JavaScript.
|
2015-12-17 09:34:15 +00:00
|
|
|
|
2017-05-19 21:05:51 +00:00
|
|
|
.content-block.emoji-block
|
2017-05-04 08:09:21 +00:00
|
|
|
.row
|
2017-05-19 21:05:51 +00:00
|
|
|
.col-sm-8
|
2017-05-04 08:09:21 +00:00
|
|
|
= render 'award_emoji/awards_block', awardable: @issue, inline: true
|
2017-05-19 21:05:51 +00:00
|
|
|
.col-sm-4.new-branch-col
|
2017-05-04 08:09:21 +00:00
|
|
|
= render 'new_branch' unless @issue.confidential?
|
2015-12-17 09:34:15 +00:00
|
|
|
|
2016-04-01 10:55:26 +00:00
|
|
|
%section.issuable-discussion
|
|
|
|
= render 'projects/issues/discussion'
|
2016-01-27 22:38:19 +00:00
|
|
|
|
2016-02-11 16:17:45 +00:00
|
|
|
= render 'shared/issuable/sidebar', issuable: @issue
|
2017-04-06 01:13:06 +00:00
|
|
|
|
2017-04-15 15:11:04 +00:00
|
|
|
= page_specific_javascript_bundle_tag('common_vue')
|
2017-04-06 01:13:06 +00:00
|
|
|
= page_specific_javascript_bundle_tag('issue_show')
|