BigW Consortium Gitlab

show.html.haml 6.23 KB
Newer Older
1
- page_title @project.name_with_namespace, "Projects"
2
%h3.page-title
3
  Project: #{@project.name_with_namespace}
4
  = link_to edit_project_path(@project), class: "btn btn-nr pull-right" do
5
    %i.fa.fa-pencil-square-o
6
    Edit
7
%hr
8
- if @project.last_repository_check_failed?
Jacob Vosmaer committed
9 10 11 12
  .row
    .col-md-12
      .panel
        .panel-heading.alert.alert-danger
13
          Last repository check
14 15
          = "(#{time_ago_in_words(@project.last_repository_check_at)} ago)"
          failed. See
Jacob Vosmaer committed
16 17
          = link_to 'repocheck.log', admin_logs_path
          for error messages.
18
.row
19
  .col-md-6
20
    .panel.panel-default
21
      .panel-heading
22 23 24 25
        Project info:
      %ul.well-list
        %li
          %span.light Name:
26
          %strong
27
            = link_to @project.name, project_path(@project)
28 29 30 31 32 33 34 35 36 37 38
        %li
          %span.light Namespace:
          %strong
            - if @project.namespace
              = link_to @project.namespace.human_name, [:admin, @project.group || @project.owner]
            - else
              Global
        %li
          %span.light Owned by:
          %strong
            - if @project.owner
39
              = link_to @project.owner_name, [:admin, @project.owner]
40 41
            - else
              (deleted)
gitlabhq committed
42

43 44 45 46
        %li
          %span.light Created by:
          %strong
            = @project.creator.try(:name) || '(deleted)'
47

48
        %li
49
          %span.light Created on:
50
          %strong
51
            = @project.created_at.to_s(:medium)
52

53 54 55
        %li
          %span.light http:
          %strong
56
            = link_to @project.http_url_to_repo, project_path(@project)
57 58 59
        %li
          %span.light ssh:
          %strong
60
            = link_to @project.ssh_url_to_repo, project_path(@project)
61 62 63 64
        - if @project.repository.exists?
          %li
            %span.light fs:
            %strong
Douwe Maan committed
65
              = @project.repository.path_to_repo
66

67
          %li
68 69 70 71 72 73 74 75 76 77
            %span.light Storage:
            %strong= storage_counter(@project.statistics.storage_size)
            (
            = storage_counter(@project.statistics.repository_size)
            repository,
            = storage_counter(@project.statistics.build_artifacts_size)
            build artifacts,
            = storage_counter(@project.statistics.lfs_objects_size)
            LFS
            )
78

79 80 81
          %li
            %span.light last commit:
            %strong
82
              = last_commit(@project)
83 84

          %li
85
            %span.light Git LFS status:
86 87
            %strong
              = project_lfs_status(@project)
88
              = link_to icon('question-circle'), help_page_path('workflow/lfs/manage_large_binaries_with_git_lfs')
89 90 91 92 93
        - else
          %li
            %span.light repository:
            %strong.cred
              does not exist
94

95 96 97 98 99
        - if @project.archived?
          %li
            %span.light archived:
            %strong repository is read-only

100 101 102
        %li
          %span.light access:
          %strong
103 104 105 106
            %span{ class: visibility_level_color(@project.visibility_level) }
              = visibility_level_icon(@project.visibility_level)
              = visibility_level_label(@project.visibility_level)

107
    .panel.panel-default
108
      .panel-heading
109
        Transfer project
110
      .panel-body
Vinnie Okada committed
111
        = form_for @project, url: transfer_admin_namespace_project_path(@project.namespace, @project), method: :put, html: { class: 'form-horizontal' } do |f|
112
          .form-group
Vinnie Okada committed
113
            = f.label :new_namespace_id, "Namespace", class: 'control-label'
114
            .col-sm-10
115 116 117 118 119 120 121
              .dropdown
                = dropdown_toggle('Search for Namespace', { toggle: 'dropdown', field_name: 'new_namespace_id', show_any: 'false' }, { toggle_class: 'js-namespace-select large' })
                .dropdown-menu.dropdown-select
                  = dropdown_title('Namespaces')
                  = dropdown_filter("Search for Namespace")
                  = dropdown_content
                  = dropdown_loading
122

123
          .form-group
124
            .col-sm-offset-2.col-sm-10
125 126
              = f.submit 'Transfer', class: 'btn btn-primary'

127
    .panel.panel-default.repository-check
Jacob Vosmaer committed
128
      .panel-heading
129
        Repository check
Jacob Vosmaer committed
130
      .panel-body
131
        = form_for @project, url: repository_check_admin_namespace_project_path(@project.namespace, @project), method: :post do |f|
Jacob Vosmaer committed
132
          .form-group
133
            - if @project.last_repository_check_at.nil?
Jacob Vosmaer committed
134 135 136
              This repository has never been checked.
            - else
              This repository was last checked
137
              = @project.last_repository_check_at.to_s(:medium) + '.'
Jacob Vosmaer committed
138
              The check
139
              - if @project.last_repository_check_failed?
Jacob Vosmaer committed
140 141 142 143 144 145 146 147
                = succeed '.' do
                  %strong.cred failed
                See
                = link_to 'repocheck.log', admin_logs_path
                for error messages.
              - else
                passed.

148
            = link_to icon('question-circle'), help_page_path('administration/repository_checks')
149

Jacob Vosmaer committed
150
          .form-group
151
            = f.submit 'Trigger repository check', class: 'btn btn-primary'
Jacob Vosmaer committed
152

153
  .col-md-6
154
    - if @group
155
      .panel.panel-default
156
        .panel-heading
157 158
          %strong= @group.name
          group members
159
          %span.badge= @group_members.size
160
          .pull-right
161
            = link_to admin_group_path(@group), class: 'btn btn-xs' do
162 163
              = icon('pencil-square-o', text: 'Manage Access')
        %ul.well-list.content-list
164
          = render partial: 'shared/members/member', collection: @group_members, as: :member, locals: { show_controls: false }
165
        .panel-footer
166
          = paginate @group_members, param_name: 'group_members_page', theme: 'gitlab'
167

168
    = render 'shared/members/requests', membership_source: @project, requesters: @requesters
169

170
    .panel.panel-default
171
      .panel-heading
172 173 174
        %strong= @project.name
        project members
        %span.badge= @project.users.size
175
        .pull-right
176 177
          = link_to icon('pencil-square-o', text: 'Manage Access'), polymorphic_url([@project, :members]), class: "btn btn-xs"
      %ul.well-list.project_members.content-list
178
        = render partial: 'shared/members/member', collection: @project_members, as: :member, locals: { show_controls: false }
179
      .panel-footer
180
        = paginate @project_members, param_name: 'project_members_page', theme: 'gitlab'