index.html.haml 2.5 KB
Newer Older
1
- @no_container = true
2 3
- @bulk_edit = can?(current_user, :admin_issue, @project)

D
Douwe Maan 已提交
4
- page_title "Issues"
5
- new_issue_email = @project.new_issue_address(current_user)
6 7
= content_for :sub_nav do
  = render "projects/issues/head"
8

9 10 11 12
= content_for :meta_tags do
  - if current_user
    = auto_discovery_link_tag(:atom, namespace_project_issues_url(@project.namespace, @project, :atom, private_token: current_user.private_token), title: "#{@project.name} issues")

13
%div{ class: (container_class) }
14
  - if @project.issues.any?
P
Phil Hughes 已提交
15 16 17 18 19 20 21 22 23 24
    .top-area
      = render 'shared/issuable/nav', type: :issues
      .nav-controls
        - if current_user
          = link_to namespace_project_issues_path(@project.namespace, @project, :atom, { private_token: current_user.private_token }), class: 'btn append-right-10' do
            = icon('rss')
            %span.icon-label
              Subscribe
        = render 'shared/issuable/search_form', path: namespace_project_issues_path(@project.namespace, @project)
        - if can? current_user, :create_issue, @project
25 26 27 28 29 30 31
          = link_to new_namespace_project_issue_path(@project.namespace,
                                                     @project,
                                                     issue: { assignee_id: issues_finder.assignee.try(:id),
                                                              milestone_id: issues_finder.milestones.first.try(:id) }),
                                                     class: "btn btn-new",
                                                     title: "New Issue",
                                                     id: "new_issue_link" do
P
Phil Hughes 已提交
32 33 34
            New Issue
    = render 'shared/issuable/filter', type: :issues

35
    .issues-holder
36
      = render 'issues'
37
      - if new_issue_email
38
        = render 'issue_by_email', email: new_issue_email
P
Phil Hughes 已提交
39 40
  - else
    .blank-state.blank-state-welcome
P
Phil Hughes 已提交
41
      %h2.blank-state-title.blank-state-welcome-title
P
Phil Hughes 已提交
42 43 44 45 46
        Welcome to GitLab Issues
      %p.blank-state-text
        Code, test, and deploy together
    .blank-state
      .blank-state-icon
47
        = custom_icon("issues", size: 50)
P
Phil Hughes 已提交
48 49 50
      %h3.blank-state-title
        You don't have any issues right now.
      %p.blank-state-text
P
Phil Hughes 已提交
51
        Issues are the best way to track your project progress
52
      - if can? current_user, :create_issue, @project
P
Phil Hughes 已提交
53
        = link_to new_namespace_project_issue_path(@project.namespace, @project), class: "btn btn-new", title: "New Issue", id: "new_issue_link" do
54
          New Issue
55
        - if new_issue_email
56
          = render 'issue_by_email', email: new_issue_email