Class: Decidim::Admin::ManagedUsers::ImpersonationLogsController

Inherits:
ApplicationController
  • Object
show all
Defined in:
app/controllers/decidim/admin/managed_users/impersonation_logs_controller.rb

Overview

Controller that allows inspecting impersonation logs

Instance Method Summary collapse

Methods inherited from ApplicationController

#permission_class_chain, #permission_scope, #user_has_no_permission_path, #user_not_authorized_path

Instance Method Details

#indexObject



11
12
13
14
15
# File 'app/controllers/decidim/admin/managed_users/impersonation_logs_controller.rb', line 11

def index
  enforce_permission_to :index, :impersonatable_user

  @impersonation_logs = Decidim::ImpersonationLog.where(user:).order(started_at: :desc).page(params[:page]).per(15)
end