Skip to content

Adjust user_avatar component to handle user gql id

Ammar Alakkad requested to merge 478487-adjust-user-avatar-to-handle-gql-id into master

What does this MR do and why?

  • Adjusts the user_avatar component to handle user id when it's a graphql id not a normal numeric id (which handles all use cases for this component)
  • Reverts "Transform user object before passing it to user-avatar" that was added in !161623 (merged), which is not unnecessary since the previous adjustment is sufficient

Related to #478487 (closed)

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Screenshots or screen recordings

Before After
Screenshot_2024-08-22_at_14.06.22 No visual changes

How to set up and validate locally

  1. Have an Ultimate License, and simulate Ultimate Self Managed setup (export GITLAB_SIMULATE_SAAS=0 gdk restart)
  2. Enable the Setting ApplicationSetting.first.update!(enable_member_promotion_management: true)
  3. Enable feature flag Feature.enable(:member_promotion_management)
  4. Create promotion requests:
    1. visit a group as an owner (not admin) (e.g. http://gdk.test:3000/groups/gitlab-org/-/group_members)
    2. promote a non-billable GUEST member to a DEVELOPER role
    3. you should see a banner saying "Role change request was sent to the administrator." — this means a promotion request has been created
  5. As root go to Admin area > Users > Promotion Requests (e.g. http://gdk.test:3000/admin/role_promotion_requests)
  6. The users listed should have a popover that displays the user details correctly
Edited by Ammar Alakkad

Merge request reports

Loading