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

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
= content_for :meta_tags do
  - if current_user
11
    = auto_discovery_link_tag(:atom, url_for(params.merge(format: :atom, private_token: current_user.private_token)), title: "#{@project.name} issues")
12

13 14
- if project_issues(@project).exists?
  %div{ class: (container_class) }
Phil Hughes's avatar
Phil Hughes committed
15 16 17 18
    .top-area
      = render 'shared/issuable/nav', type: :issues
      .nav-controls
        - if current_user
19
          = link_to url_for(params.merge(format: :atom, private_token: current_user.private_token)), class: 'btn append-right-10' do
Phil Hughes's avatar
Phil Hughes committed
20 21 22 23 24
            = 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
Phil Hughes's avatar
Phil Hughes committed
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
39 40
- else
  = render 'shared/empty_states/issues', button_path: new_namespace_project_issue_path(@project.namespace, @project)