index.html.haml 7.43 KB
Newer Older
Annabel Dunstone's avatar
Annabel Dunstone committed
1
- @no_container = true
Phil Hughes's avatar
Phil Hughes committed
2
- breadcrumb_title "Dashboard"
3

Valery Sizov's avatar
Valery Sizov committed
4
%div{ class: container_class }
5
  = render_if_exists 'admin/licenses/breakdown', license: @license
6

Annabel Dunstone's avatar
Annabel Dunstone committed
7
  .admin-dashboard.prepend-top-default
8
9
10
11
12
13
14
    .row
      .col-sm-4
        .info-well.dark-well
          .well-segment.well-centered
            = link_to admin_projects_path do
              %h3.text-center
                Projects:
15
                = approximate_count_with_delimiters(@counts, Project)
16
17
18
19
20
21
22
23
            %hr
            = link_to('New project', new_project_path, class: "btn btn-new")
      .col-sm-4
        .info-well.dark-well
          .well-segment.well-centered
            = link_to admin_users_path do
              %h3.text-center
                Users:
24
                = approximate_count_with_delimiters(@counts, User)
25
            = render_if_exists 'admin/dashboard/users_statistics'
26
27
28
29
30
31
32
33
            %hr
            = link_to 'New user', new_admin_user_path, class: "btn btn-new"
      .col-sm-4
        .info-well.dark-well
          .well-segment.well-centered
            = link_to admin_groups_path do
              %h3.text-center
                Groups:
34
                = approximate_count_with_delimiters(@counts, Group)
35
36
            %hr
            = link_to 'New group', new_admin_group_path, class: "btn btn-new"
Annabel Dunstone's avatar
Annabel Dunstone committed
37
38
    .row
      .col-md-4
39
        .info-well
Jacopo's avatar
Jacopo committed
40
          .well-segment.admin-well.admin-well-statistics
41
42
43
            %h4 Statistics
            %p
              Forks
44
              %span.light.float-right
45
                = approximate_count_with_delimiters(@counts, ForkedProjectLink)
46
47
            %p
              Issues
48
              %span.light.float-right
49
                = approximate_count_with_delimiters(@counts, Issue)
50
51
            %p
              Merge Requests
52
              %span.light.float-right
53
                = approximate_count_with_delimiters(@counts, MergeRequest)
54
55
            %p
              Notes
56
              %span.light.float-right
57
                = approximate_count_with_delimiters(@counts, Note)
58
59
            %p
              Snippets
60
              %span.light.float-right
61
                = approximate_count_with_delimiters(@counts, Snippet)
62
63
            %p
              SSH Keys
64
              %span.light.float-right
65
                = approximate_count_with_delimiters(@counts, Key)
66
67
            %p
              Milestones
68
              %span.light.float-right
69
                = approximate_count_with_delimiters(@counts, Milestone)
70
71
            %p
              Active Users
72
              %span.light.float-right
73
                = number_with_delimiter(User.active.count)
Annabel Dunstone's avatar
Annabel Dunstone committed
74
      .col-md-4
75
        .info-well
Jacopo's avatar
Jacopo committed
76
          .well-segment.admin-well.admin-well-features
77
78
            %h4 Features
            - sign_up = "Sign up"
79
            %p{ "aria-label" => "#{sign_up}: status " + (allow_signup? ? "on" : "off") }
80
              = sign_up
81
              %span.light.float-right
82
                = boolean_to_icon allow_signup?
83
84
85
            - ldap = "LDAP"
            %p{ "aria-label" => "#{ldap}: status " + (Gitlab.config.ldap.enabled ? "on" : "off") }
              = ldap
86
              %span.light.float-right
87
88
89
90
                = boolean_to_icon Gitlab.config.ldap.enabled
            - gravatar = "Gravatar"
            %p{ "aria-label" => "#{gravatar}: status " + (gravatar_enabled? ? "on" : "off") }
              = gravatar
91
              %span.light.float-right
92
93
94
95
                = boolean_to_icon gravatar_enabled?
            - omniauth = "OmniAuth"
            %p{ "aria-label" => "#{omniauth}: status " + (Gitlab.config.omniauth.enabled ? "on" : "off") }
              = omniauth
96
              %span.light.float-right
97
98
99
100
                = boolean_to_icon Gitlab.config.omniauth.enabled
            - reply_email = "Reply by email"
            %p{ "aria-label" => "#{reply_email}: status " + (Gitlab::IncomingEmail.enabled? ? "on" : "off") }
              = reply_email
101
              %span.light.float-right
102
                = boolean_to_icon Gitlab::IncomingEmail.enabled?
103

104
            = render_if_exists 'admin/dashboard/elastic_and_geo'
105

106
107
108
            - container_reg = "Container Registry"
            %p{ "aria-label" => "#{container_reg}: status " + (Gitlab.config.registry.enabled ? "on" : "off") }
              = container_reg
109
              %span.light.float-right
110
111
112
113
114
                = boolean_to_icon Gitlab.config.registry.enabled
            - gitlab_pages = 'GitLab Pages'
            - gitlab_pages_enabled = Gitlab.config.pages.enabled
            %p{ "aria-label" => "#{gitlab_pages}: status " + (gitlab_pages_enabled ? "on" : "off") }
              = gitlab_pages
115
              %span.light.float-right
116
117
118
119
120
                = boolean_to_icon gitlab_pages_enabled
            - gitlab_shared_runners = 'Shared Runners'
            - gitlab_shared_runners_enabled = Gitlab.config.gitlab_ci.shared_runners_enabled
            %p{ "aria-label" => "#{gitlab_shared_runners}: status " + (gitlab_shared_runners_enabled ? "on" : "off") }
              = gitlab_shared_runners
121
              %span.light.float-right
122
                = boolean_to_icon gitlab_shared_runners_enabled
Annabel Dunstone's avatar
Annabel Dunstone committed
123
      .col-md-4
124
125
126
127
        .info-well
          .well-segment.admin-well
            %h4
              Components
128
              - if Gitlab::CurrentSettings.version_check_enabled
129
                .float-right
130
131
132
                  = version_status_badge
            %p
              GitLab
133
              %span.float-right
134
                = Gitlab::VERSION
135
                = "(#{Gitlab.revision})"
136
137
            %p
              GitLab Shell
138
              %span.float-right
139
140
141
                = Gitlab::Shell.new.version
            %p
              GitLab Workhorse
142
              %span.float-right
143
144
145
                = gitlab_workhorse_version
            %p
              GitLab API
146
              %span.float-right
147
                = API::API::version
148
149
150
            - if Gitlab.config.pages.enabled
              %p
                GitLab Pages
151
                %span.float-right
152
                  = Gitlab::Pages::VERSION
153

154
            = render_if_exists 'admin/dashboard/geo'
155

156
157
            %p
              Ruby
158
              %span.float-right
159
160
161
                #{RUBY_VERSION}p#{RUBY_PATCHLEVEL}
            %p
              Rails
162
              %span.float-right
163
164
165
                #{Rails::VERSION::STRING}
            %p
              = Gitlab::Database.adapter_name
166
              %span.float-right
167
                = Gitlab::Database.version
168
169
            %p
              = link_to "Gitaly Servers", admin_gitaly_servers_path
170
    .row
Annabel Dunstone's avatar
Annabel Dunstone committed
171
      .col-md-4
172
173
174
175
176
        .info-well
          .well-segment.admin-well
            %h4 Latest projects
            - @projects.each do |project|
              %p
177
                = link_to project.full_name, [:admin, project.namespace.becomes(Namespace), project], class: 'str-truncated-60'
178
                %span.light.float-right
179
                  #{time_ago_with_tooltip(project.created_at)}
Annabel Dunstone's avatar
Annabel Dunstone committed
180
      .col-md-4
181
182
183
184
185
186
187
        .info-well
          .well-segment.admin-well
            %h4 Latest users
            - @users.each do |user|
              %p
                = link_to [:admin, user], class: 'str-truncated-60' do
                  = user.name
188
                %span.light.float-right
189
                  #{time_ago_with_tooltip(user.created_at)}
Annabel Dunstone's avatar
Annabel Dunstone committed
190
      .col-md-4
191
192
193
194
195
196
197
        .info-well
          .well-segment.admin-well
            %h4 Latest groups
            - @groups.each do |group|
              %p
                = link_to [:admin, group], class: 'str-truncated-60' do
                  = group.full_name
198
                %span.light.float-right
199
                  #{time_ago_with_tooltip(group.created_at)}