diff --git a/app/assets/javascripts/admin/routes/admin_dashboard_route.js b/app/assets/javascripts/admin/routes/admin_dashboard_route.js
index 8f3176acb28..34c9b338360 100644
--- a/app/assets/javascripts/admin/routes/admin_dashboard_route.js
+++ b/app/assets/javascripts/admin/routes/admin_dashboard_route.js
@@ -26,7 +26,8 @@ Discourse.AdminDashboardRoute = Discourse.Route.extend({
d.reports.each(function(report){
c.set(report.type, Discourse.Report.create(report));
});
- c.set('totalUsers', d.total_users);
+ c.set('admins', d.admins);
+ c.set('moderators', d.moderators);
c.set('problems', d.problems);
c.set('loading', false);
});
diff --git a/app/assets/javascripts/admin/templates/dashboard.js.handlebars b/app/assets/javascripts/admin/templates/dashboard.js.handlebars
index c95cff20fcd..e5b441480ae 100644
--- a/app/assets/javascripts/admin/templates/dashboard.js.handlebars
+++ b/app/assets/javascripts/admin/templates/dashboard.js.handlebars
@@ -71,7 +71,6 @@
2 |
3 |
4 |
- {{i18n admin.dashboard.moderator_short}} |
{{#unless loading}}
@@ -80,6 +79,21 @@
+
+
+
+
+ {{i18n admin.dashboard.moderators}} |
+ {{moderators}} |
+
+
+ {{i18n admin.dashboard.admins}} |
+ {{admins}} |
+
+
+
+
+
diff --git a/app/assets/javascripts/admin/templates/reports/trust_levels_report.js.handlebars b/app/assets/javascripts/admin/templates/reports/trust_levels_report.js.handlebars
index 842705c2c35..b4f3d7490b3 100644
--- a/app/assets/javascripts/admin/templates/reports/trust_levels_report.js.handlebars
+++ b/app/assets/javascripts/admin/templates/reports/trust_levels_report.js.handlebars
@@ -5,5 +5,4 @@
{{valueAtTrustLevel data 2}} |
{{valueAtTrustLevel data 3}} |
{{valueAtTrustLevel data 4}} |
- {{valueAtTrustLevel data 5}} |
\ No newline at end of file
diff --git a/app/assets/stylesheets/admin/admin_base.scss b/app/assets/stylesheets/admin/admin_base.scss
index 636600def27..c7428b4b8b3 100644
--- a/app/assets/stylesheets/admin/admin_base.scss
+++ b/app/assets/stylesheets/admin/admin_base.scss
@@ -394,22 +394,27 @@ table {
&.totals {
width: 160px;
+ margin-top: 0px;
- table tr:first-child td {
+ table td {
border-top: none;
+ &.value {
+ text-align: left;
+ width: 55px;
+ }
}
}
&.trust-levels {
margin-top: 0px;
- td.value {
- width: 33px;
+ table {
+ margin-bottom: 0px;
}
- }
- &.total-users {
- margin-left: 45px;
+ td.value {
+ width: 45px;
+ }
}
}
diff --git a/app/models/admin_dashboard_data.rb b/app/models/admin_dashboard_data.rb
index 9db1e700bd1..d7a32348f8c 100644
--- a/app/models/admin_dashboard_data.rb
+++ b/app/models/admin_dashboard_data.rb
@@ -11,7 +11,9 @@ class AdminDashboardData
def as_json
@json ||= {
reports: REPORTS.map { |type| Report.find(type) },
- problems: [rails_env_check, host_names_check, gc_checks, sidekiq_check || clockwork_check, ram_check].compact
+ problems: [rails_env_check, host_names_check, gc_checks, sidekiq_check || clockwork_check, ram_check].compact,
+ admins: User.where(admin: true).count,
+ moderators: User.where(moderator: true).count
}.merge(
SiteSetting.version_checks? ? {version_check: DiscourseUpdates.check_version} : {}
)
diff --git a/config/locales/client.en.yml b/config/locales/client.en.yml
index 461a17e85ce..10079da61fb 100644
--- a/config/locales/client.en.yml
+++ b/config/locales/client.en.yml
@@ -700,8 +700,9 @@ en:
installed_version: "Installed"
latest_version: "Latest"
update_often: 'Please update often!'
- moderator_short: "mod"
problems_found: "Some problems have been found with your installation of Discourse:"
+ moderators: 'Moderators:'
+ admins: 'Admins:'
reports:
today: "Today"