From: Anton Khorev Date: Fri, 18 Aug 2023 15:48:38 +0000 (+0300) Subject: Add 'User' to selectable types in issues search for moderators X-Git-Tag: live~1075^2 X-Git-Url: https://git.openstreetmap.org./rails.git/commitdiff_plain/1acd8e25a7d531dd264efa2c98265d6abf8f0b74?hp=-c Add 'User' to selectable types in issues search for moderators Reported users are either directly assigned to moderators or ofter reassigned to them. --- 1acd8e25a7d531dd264efa2c98265d6abf8f0b74 diff --git a/app/controllers/issues_controller.rb b/app/controllers/issues_controller.rb index c381119f0..88c7a46ac 100644 --- a/app/controllers/issues_controller.rb +++ b/app/controllers/issues_controller.rb @@ -14,7 +14,7 @@ class IssuesController < ApplicationController @title = t ".title" @issue_types = [] - @issue_types.push("Note") if current_user.moderator? + @issue_types.push("Note", "User") if current_user.moderator? @issue_types.push("DiaryEntry", "DiaryComment", "User") if current_user.administrator? @users = User.joins(:roles).where(:user_roles => { :role => current_user.roles.map(&:role) }).distinct