diff --git a/html/lang/strings_english.txt b/html/lang/strings_english.txt
index 587d9c9..e8b62c0 100644
--- a/html/lang/strings_english.txt
+++ b/html/lang/strings_english.txt
@@ -723,6 +723,7 @@ $s_documentation_link = 'Documentation';
$s_new_accounts_title = 'New Accounts';
$s_1_week_title = '1 Week';
$s_never_logged_in_title = 'Never Logged In';
+$s_no_activity_title = 'No User Activity';
$s_prune_accounts = 'Prune Accounts';
$s_hide_inactive = 'Hide Inactive';
$s_show_disabled = 'Show Disabled';
@@ -1806,4 +1807,5 @@ $s_filter_all = 'All';
$s_filter_new = 'New';
$s_filter_unused_tags = 'Unused';
$s_filter_unused = 'Unused';
+$s_filter_no_activity = 'No Activity';
$s_unknown = 'unknown';
diff --git a/html/manage_user_page.php b/html/manage_user_page.php
index b6f4e37..034694c 100644
--- a/html/manage_user_page.php
+++ b/html/manage_user_page.php
@@ -144,6 +144,7 @@ $t_prefix_array = array_merge (
[
'UNUSED' => lang_get( 'filter_unused' ),
'NEW' => lang_get( 'filter_new' ),
+ 'NO_ACTIVITY' => lang_get( 'filter_no_activity' ),
]
);
@@ -163,6 +164,9 @@ foreach ( $t_prefix_array as $t_prefix => $t_caption ) {
} else if( $t_prefix === 'NEW' ) {
$t_search = '';
$t_title = ' title="[' . $t_new_user_count . '] (' . lang_get( '1_week_title' ) . ')"';
+ } else if( $t_prefix === 'NO_ACTIVITY' ) {
+ $t_search = '';
+ $t_title = ' title="' . lang_get( 'no_activity_title' ) . '"';
} else {
$t_search = $f_search;
$t_title = '';
@@ -186,6 +190,14 @@ if( $f_filter === 'ALL' ) {
$t_where = '(1 = 1)';
} else if( $f_filter === 'UNUSED' ) {
$t_where = '(login_count = 0) AND ( date_created = last_visit )';
+} else if( $f_filter === 'NO_ACTIVITY' ) {
+ $t_wheres = [
+ 'NOT EXISTS (SELECT * from {bug} WHERE {user}.id = {bug}.reporter_id)',
+ 'NOT EXISTS (SELECT * from {bugnote} WHERE {user}.id = {bugnote}.reporter_id)',
+ 'NOT EXISTS (SELECT * from {bug_file} WHERE {user}.id = {bug_file}.user_id)',
+ 'NOT EXISTS (SELECT * from {bug_monitor} WHERE {user}.id = {bug_monitor}.user_id)',
+ ];
+ $t_where = implode( ' AND ', $t_wheres );
} else if( $f_filter === 'NEW' ) {
$t_where = db_helper_compare_time( db_param(), '<=', 'date_created', $t_days_old );
$t_where_params[] = db_now();