Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2023-12-04 12:13:06 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2023-12-04 12:13:06 +0300
commit6974ffffd292657d8257826b2e09a0a8fff6c6a8 (patch)
treec4cb8005ff9158a92cb8d87e2992603e7b8f8cd6 /app/controllers
parent3f7324cf3aefa10a3b2126683e7d61e595bc210a (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/controllers')
-rw-r--r--app/controllers/profiles_controller.rb11
-rw-r--r--app/controllers/user_settings/user_settings_controller.rb16
2 files changed, 16 insertions, 11 deletions
diff --git a/app/controllers/profiles_controller.rb b/app/controllers/profiles_controller.rb
index cb29f0f3539..e427f607186 100644
--- a/app/controllers/profiles_controller.rb
+++ b/app/controllers/profiles_controller.rb
@@ -14,7 +14,6 @@ class ProfilesController < Profiles::ApplicationController
feature_category :user_profile, [:show, :update, :reset_incoming_email_token, :reset_feed_token,
:reset_static_object_token, :update_username]
- feature_category :system_access, [:audit_log]
urgency :low, [:show, :update]
def show
@@ -65,16 +64,6 @@ class ProfilesController < Profiles::ApplicationController
notice: s_('Profiles|Static object token was successfully reset')
end
- # rubocop: disable CodeReuse/ActiveRecord
- def audit_log
- @events = AuthenticationEvent.where(user: current_user)
- .order("created_at DESC")
- .page(params[:page])
-
- Gitlab::Tracking.event(self.class.name, 'search_audit_event', user: current_user)
- end
- # rubocop: enable CodeReuse/ActiveRecord
-
def update_username
result = Users::UpdateService.new(current_user, user: @user, username: username_param).execute
diff --git a/app/controllers/user_settings/user_settings_controller.rb b/app/controllers/user_settings/user_settings_controller.rb
new file mode 100644
index 00000000000..3d69a9c2fd6
--- /dev/null
+++ b/app/controllers/user_settings/user_settings_controller.rb
@@ -0,0 +1,16 @@
+# frozen_string_literal: true
+
+module UserSettings
+ class UserSettingsController < ApplicationController
+ layout 'profile'
+ feature_category :system_access
+
+ def authentication_log
+ @events = AuthenticationEvent.for_user(current_user)
+ .order_by_created_at_desc
+ .page(params[:page])
+
+ Gitlab::Tracking.event(self.class.name, 'search_audit_event', user: current_user)
+ end
+ end
+end