From 1be69039bc57c8402fbd19c8b40b72045808e71f Mon Sep 17 00:00:00 2001 From: Yannick Warnier Date: Sun, 31 May 2020 07:37:00 +0200 Subject: [PATCH] Admin: Add new block with online users in the last 3, 5, 30 and 120 minutes to avoid having to enable global display of online users count - refs BT#17261 --- main/admin/statistics/index.php | 59 +++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) diff --git a/main/admin/statistics/index.php b/main/admin/statistics/index.php index b3ed6eaf8a..588acf9478 100755 --- a/main/admin/statistics/index.php +++ b/main/admin/statistics/index.php @@ -352,6 +352,7 @@ $tools = [ 'report=no_login_users' => get_lang('StatsUsersDidNotLoginInLastPeriods'), 'report=zombies' => get_lang('Zombies'), 'report=users_active' => get_lang('UserStats'), + 'report=users_online' => get_lang('UsersOnline'), ], get_lang('System') => [ 'report=activities' => get_lang('ImportantActivities'), @@ -1313,6 +1314,64 @@ switch ($report) { $content = $form->returnForm().$content; + break; + case 'users_online': + $content = '
+
+
+
+
+ + + +
+
'.get_lang('UsersOnline').' (3\')
+
'.getOnlineUsersCount(3).'
+
+
+
+
+
+
+
+ + + +
+
'.get_lang('UsersOnline').' (5\')
+
'.getOnlineUsersCount(5).'
+
+
+
+
+
+
+
+ + + +
+
'.get_lang('UsersOnline').' (30\')
+
'.getOnlineUsersCount(30).'
+
+
+
+
+
+
+
+ + + +
+
'.get_lang('UsersOnline').' (120\')
+
'.getOnlineUsersCount(120).'
+
+
+
+
+
+
'; break; case 'users': $content .= '
';