Skip to content

Fix 404 when purchasing storage from a subgroup

Bruno Freitas requested to merge 361472-buy-storage-path-use-root-group into master

What does this MR do and why?

Update the selected_group id in Buy Storage URL to always use the root ancestor group ID. This fixes the issue where a user would be redirected to 404 page when they click on the purchase storage alert displayed in projects within a subgroup.

Solves issue

cc: @ffarukh

How to set up and validate locally

  1. Create a group, subgroups, and projects in the subgroup
  2. Upload a file to consume all your storage quota
    • If you have admin access, you can edit the group and reduce the quota
  3. Navigate to either:
    • The main page of project in the subgroup
  4. Click "Purchase more storage"
  5. You should be redirected to the Purchase flow. Note: You need CustomersDot installed, running, and configured with your local GitLab in order for the checkout page to render correctly.

MR acceptance checklist

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

Related to #361472 (closed)

Merge request reports