Skip to content

Update copy and UI of Review reassignment page

What does this MR do and why?

  • Update copy of Review reassignment page and HTML / text emails.
  • Use CardComponent for UI.

Changelog: changed

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

Page Email (HTML) Email (Text)
Review_reassignment_page Review_reassignment_email Review_reassignment_email_text

How to set up and validate locally

  1. In a Rails console, create a new Import::SourceUser:
source_user = FactoryBot.create(:import_source_user, namespace: Group.first.root_ancestor)

And then do the following to get a <SOURCE_USER_ID> to use in the mutations:

source_user.to_global_id.to_s
  1. Use GraphiQL http://gdk.test:3000/-/graphql-explorer to send mutation requests:
mutation {
  importSourceUserReassign(input: { id: "<SOURCE_USER_ID>", assigneeUserId: "gid://gitlab/User/1" }) {
    importSourceUser {
      status
    }
  }
}
  1. Checkout this branch and restart GDK (️ Important: Restarting is needed to view the email previews as they seem to be cached).
  2. Go to http://127.0.0.1:3000/rails/mailers and preview the import_source_user_reassign email template:
    • HTML: http://127.0.0.1:3000/rails/mailers/notify/import_source_user_reassign.html?locale=en
    • Text: http://127.0.0.1:3000/rails/mailers/notify/import_source_user_reassign.txt?locale=en
  3. Click Review reassignment details in the email. You should be redirected to an URL that looks like http://127.0.0.1:3000/import/source_users/548.
  4. Apply this diff you get a 404 Not Found:
diff --git a/app/controllers/import/source_users_controller.rb b/app/controllers/import/source_users_controller.rb
index 560dd0c88dfe..d33431e0dffa 100644
--- a/app/controllers/import/source_users_controller.rb
+++ b/app/controllers/import/source_users_controller.rb
@@ -5,7 +5,7 @@ class SourceUsersController < ApplicationController
     prepend_before_action :check_feature_flag!
 
     before_action :source_user
-    before_action :check_current_user_matches_invite!
+    # before_action :check_current_user_matches_invite!
 
     respond_to :html
     feature_category :importers

Related to #467368

Edited by Justin Ho Tuan Duong

Merge request reports