_project.html.haml 2.6 KB
Newer Older
1
%ul.project-navigation.nav.nav-sidebar
D
Dmitriy Zaporozhets 已提交
2
  = nav_link(path: 'projects#show', html_options: {class: "home"}) do
3
    = link_to project_path(@project), title: 'Project', class: 'shortcuts-project' do
D
Dmitriy Zaporozhets 已提交
4
      %i.fa.fa-dashboard
5 6
      %span
        Project
7
  - if project_nav_tab? :files
8
    = nav_link(controller: %w(tree blob blame edit_tree new_tree)) do
D
Dmitriy Zaporozhets 已提交
9 10
      = link_to project_tree_path(@project, @ref || @repository.root_ref), class: 'shortcuts-tree' do
        %i.fa.fa-files-o
11 12
        %span
          Files
D
Dmitriy Zaporozhets 已提交
13

14 15

  - if project_nav_tab? :commits
16
    = nav_link(controller: %w(commit commits compare repositories tags branches)) do
D
Dmitriy Zaporozhets 已提交
17 18
      = link_to project_commits_path(@project, @ref || @repository.root_ref), class: 'shortcuts-commits' do
        %i.fa.fa-history
19 20
        %span
          Commits
21 22 23

  - if project_nav_tab? :network
    = nav_link(controller: %w(network)) do
D
Dmitriy Zaporozhets 已提交
24 25
      = link_to project_network_path(@project, @ref || @repository.root_ref), class: 'shortcuts-network' do
        %i.fa.fa-code-fork
26 27
        %span
          Network
28 29 30

  - if project_nav_tab? :graphs
    = nav_link(controller: %w(graphs)) do
D
Dmitriy Zaporozhets 已提交
31 32
      = link_to project_graph_path(@project, @ref || @repository.root_ref), class: 'shortcuts-graphs' do
        %i.fa.fa-area-chart
33 34
        %span
          Graphs
35 36

  - if project_nav_tab? :issues
D
Dmitriy Zaporozhets 已提交
37
    = nav_link(controller: %w(issues milestones labels)) do
R
Robert Schilling 已提交
38
      = link_to url_for_project_issues, class: 'shortcuts-issues' do
D
Dmitriy Zaporozhets 已提交
39
        %i.fa.fa-exclamation-circle
40 41 42 43
        %span
          Issues
          - if @project.used_default_issues_tracker?
            %span.count.issue_counter= @project.issues.opened.count
D
Dmitriy Zaporozhets 已提交
44

45
  - if project_nav_tab? :merge_requests
D
Dmitriy Zaporozhets 已提交
46
    = nav_link(controller: :merge_requests) do
R
Robert Schilling 已提交
47
      = link_to project_merge_requests_path(@project), class: 'shortcuts-merge_requests'  do
D
Dmitriy Zaporozhets 已提交
48
        %i.fa.fa-tasks
49 50 51
        %span
          Merge Requests
          %span.count.merge_counter= @project.merge_requests.opened.count
D
Dmitriy Zaporozhets 已提交
52

53
  - if project_nav_tab? :wiki
D
Dmitriy Zaporozhets 已提交
54
    = nav_link(controller: :wikis) do
D
Dmitriy Zaporozhets 已提交
55 56
      = link_to project_wiki_path(@project, :home), class: 'shortcuts-wiki' do
        %i.fa.fa-book
57 58
        %span
          Wiki
D
Dmitriy Zaporozhets 已提交
59

60
  - if project_nav_tab? :snippets
D
Dmitriy Zaporozhets 已提交
61
    = nav_link(controller: :snippets) do
D
Dmitriy Zaporozhets 已提交
62 63
      = link_to project_snippets_path(@project), class: 'shortcuts-snippets' do
        %i.fa.fa-file-text-o
64 65
        %span
          Snippets
D
Dmitriy Zaporozhets 已提交
66

67
  - if project_nav_tab? :settings
68
    = nav_link(html_options: {class: "#{project_tab_class} separate-item"}) do
69
      = link_to edit_project_path(@project), class: "stat-tab tab no-highlight" do
D
Dmitriy Zaporozhets 已提交
70
        %i.fa.fa-cogs
71 72 73
        %span
          Settings
          %i.fa.fa-angle-down
74 75

  - if @project_settings_nav
76
    = render 'projects/settings_nav'