diff options
author | Jacob Schatz <jschatz@gitlab.com> | 2016-07-07 21:17:23 +0000 |
---|---|---|
committer | Jacob Schatz <jschatz@gitlab.com> | 2016-07-07 21:17:23 +0000 |
commit | 5541e55c491eb86567c8c1f28457e894a4155dd1 (patch) | |
tree | 1fd84776d751c33665aca26c1e4d4eac624fd295 /app/views/projects | |
parent | 86d238e4bda6424a79eb9d8ea7cfe41af714f49f (diff) | |
parent | e486bbfd34bc962ddc6e7a0433a5b0cce74603a7 (diff) | |
download | gitlab-ce-5541e55c491eb86567c8c1f28457e894a4155dd1.tar.gz |
Merge branch 'issues-blank-state' into 'master'
Added blank state to issues
## What does this MR do?
Adds new blank state to issues when no issues exist.
Part of #18519
## Screenshots (if relevant)
![Screen_Shot_2016-06-24_at_16.37.12](/uploads/0c3f385615b29216ef1137bd6fac06af/Screen_Shot_2016-06-24_at_16.37.12.png)
See merge request !4908
Diffstat (limited to 'app/views/projects')
-rw-r--r-- | app/views/projects/issues/index.html.haml | 48 |
1 files changed, 32 insertions, 16 deletions
diff --git a/app/views/projects/issues/index.html.haml b/app/views/projects/issues/index.html.haml index 7ce4c1e5555..312bd86ed04 100644 --- a/app/views/projects/issues/index.html.haml +++ b/app/views/projects/issues/index.html.haml @@ -6,21 +6,37 @@ - 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") -%div{ class: container_class } - .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) +%div{ class: (container_class) } + - if @project.issues.any? + .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 + = link_to new_namespace_project_issue_path(@project.namespace, @project, issue: { assignee_id: @issuable_finder.assignee.try(:id), milestone_id: @issuable_finder.milestones.try(:first).try(:id) }), class: "btn btn-new", title: "New Issue", id: "new_issue_link" do + New Issue + = render 'shared/issuable/filter', type: :issues + + .issues-holder + = render "issues" + - else + .blank-state.blank-state-welcome + %h2.blank-state-title.blank-state-welcome-title + Welcome to GitLab Issues + %p.blank-state-text + Code, test, and deploy together + .blank-state + .blank-state-icon + = navbar_icon("issues", size: 50) + %h3.blank-state-title + You don't have any issues right now. + %p.blank-state-text + Issues are the best way to track your project progress - if can? current_user, :create_issue, @project - = link_to new_namespace_project_issue_path(@project.namespace, @project, issue: { assignee_id: @issuable_finder.assignee.try(:id), milestone_id: @issuable_finder.milestones.try(:first).try(:id) }), class: "btn btn-new", title: "New Issue", id: "new_issue_link" do + = link_to new_namespace_project_issue_path(@project.namespace, @project), class: "btn btn-new", title: "New Issue", id: "new_issue_link" do New Issue - - = render 'shared/issuable/filter', type: :issues - - .issues-holder - = render "issues" |