Skip to content

Indicate locked users in Admin Area users list

What does this MR do and why?

Related to #349848 (closed)

A user is locked after 10 failed login attempts. The lock expires after 10 minutes. An Admin can unlock a user from the Rails console or the Admin Area.

Previously there was no indication in the Admin Area user list view that a user is locked. This MR adds a Locked badge next to users that are locked.

Screenshots or screen recordings

Before After
Screen_Shot_2022-01-25_at_12.28.46_PM Screen_Shot_2022-01-25_at_12.43.03_PM

How to set up and validate locally

  1. Sign in as an Admin.
  2. Navigate to /admin/users.
  3. Click on a user and make note of their username.
  4. In the Rails console (bin/rails console) run User.find_by_username(<Username from step 3>).update_column(:locked_at, DateTime.current).
  5. Navigate back to the listing view. There should be a Locked badge next to the locked user

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Peter Hegman

Merge request reports

Loading