index.html.haml 1.3 KB
Newer Older
R
randx 已提交
1
%h3.page_title
2
  Projects (#{Project.count})
3
  = link_to 'New Project', new_project_path, class: "btn small right"
R
randx 已提交
4
%br
C
Cyril 已提交
5
= form_tag admin_projects_path, method: :get, class: 'form-inline' do
6
  = select_tag :namespace_id, namespaces_options(params[:namespace_id], :all), class: "chosen xlarge", prompt: "Project namespace"
7 8
  = text_field_tag :name, params[:name], class: "xlarge"
  = submit_tag "Search", class: "btn submit primary"
R
randx 已提交
9

R
randx 已提交
10
%table
G
gitlabhq 已提交
11
  %thead
C
Cyril 已提交
12 13 14 15 16 17
    %tr
      %th
        Name
        %i.icon-sort-down
      %th Path
      %th Team Members
18
      %th Owner
C
Cyril 已提交
19 20 21
      %th Last Commit
      %th Edit
      %th.cred Danger Zone!
G
gitlabhq 已提交
22

23
  - @projects.each do |project|
G
gitlabhq 已提交
24
    %tr
25
      %td
26
        = link_to project.name_with_namespace, [:admin, project]
27 28
      %td
        %span.monospace= project.path_with_namespace + ".git"
G
gitlabhq 已提交
29
      %td= project.users_projects.count
30
      %td
31 32 33 34
        - if project.owner
          = link_to project.owner.name, [:admin, project.owner]
        - else
          (deleted)
G
gitlabhq 已提交
35
      %td= last_commit(project)
36 37
      %td= link_to 'Edit', edit_admin_project_path(project), id: "edit_#{dom_id(project)}", class: "btn small"
      %td.bgred= link_to 'Destroy', [:admin, project], confirm: "REMOVE #{project.name}? Are you sure?", method: :delete, class: "btn small danger"
38
= paginate @projects, theme: "admin"