Show `email_reset_offered_at` to admin users
What does this MR do and why?
Allow admin users to see if a user has reset their email or not through the Account email verification process
Related issues:
- gitlab-com/support/support-team-meta#5669 (comment 1661320749)
- 16.3 Support Readiness - (Aug 16 release) Requi... (gitlab-com/support/support-team-meta#5359 - closed)
Screenshots or screen recordings
For Admin area:
Before | After |
---|---|
How to set up and validate locally
- Create a new user
- View the admin area for the user profile. Eg.
http://<gitlab-instance-domain>/admin/users/<myusername>
. There should now be aEmail reset done at
row with a value ofNever
. - View the API for that user. Eg.
http://<gitlab-instance-domain>/api/v4/users?search=<myusername>
. There should be aemail_reset_offered_at
item with a value ofnull
. - Open up the rails console, and run the following (Assume the ID of the user we created is
13
):user = User.find(13) user.email_reset_offered_at = 1.hour.ago user.save!
- View the admin area for the user profile. Eg.
http://<gitlab-instance-domain>/admin/users/<myusername>
. There should now be aEmail reset done at
row with a timestamp from an hour ago. - View the API for that user. Eg.
http://<gitlab-instance-domain>/api/v4/users?search=<myusername>
. There should be aemail_reset_offered_at
item with a timestamp from an hour ago.
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.