Skip to content

Fix pending members view

Nicolas Dular requested to merge nd/fix-pending-members-view into master

What does this MR do and why?

The pending members view is part of the groups/usage_quotas page where we try to initialilze the NamespaceStorage Vue application as well.

However, as we don't render the #js-storage-counter-app element with the data for the Vue application, initNamespaceStorage raises an error.

To fix this, we don't try to initialize the Vue Application and return early (as we do it for the other Vue applications as well).

No changelog because it's behind the feature flag saas_user_caps.

Screenshots or screen recordings

Before After
Screenshot_2022-05-24_at_13.20.57 Screenshot_2022-05-24_at_15.35.22

How to set up and validate locally

  1. Stop your gdk
  2. export GITLAB_SIMULATE_SAAS=1
  3. gdk start
  4. bin/rails c
  5. Feature.enable(:saas_user_caps)
  6. ApplicationSetting.first.update(check_namespace_plan: true)
  7. Go to Admin > Groups. Choose a group and give it a paid plan
  8. Go to the rails console again bin/rails c to set a member to be awaiting, e.g.
    group = Group.find(ID_OF_YOUR_GROUP) # find your group's ID
    group.members.last.wait!
  9. Go to the Group's Usage Quota Page (Group > Settings > Usage Quota)
  10. You should see the banner "Pending members", click on it, you see the page

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 Nicolas Dular

Merge request reports