Skip to content

Adds redirection when cleanup policy is saved

What does this MR do and why?

Forth MR under move container registry cleanup policies to a separate page.

This MR deals with redirection to settings page when Save changes/Cancel is clicked on cleanup image tags page described in comment

It also fixes issue where clean up page allows saving changes when no changes are made.

Iteration MR
Adds new route Adds new route to show cleanup image tag settings (!94988 - merged)
Copy container cleanup form Copies container registry cleanup form to new page (!96219 - merged)
Update settings page to link new route Updates container registry project settings (!96799 - merged)
Redirect to settings page when saved or canceled This MR

Noticed and fixed issue with settings submenu not being expanded for cleanup image tags page

Screenshots or screen recordings

Cleanup image tags form

Screen_Shot_2022-09-12_at_2.47.40_pm

Alert

Screen_Shot_2022-09-06_at_1.21.31_pm

If Updates container registry project settings (!96799 - merged) gets merged before this then the settings page should look different to screenshot but the alert & redirection behavior should remain

How to set up and validate locally

  1. Enable container registry in GDK https://gitlab.com/gitlab-org/gitlab-development-kit/-/blob/main/doc/howto/registry.md
  2. Login as admin
  3. Visit any project.
  4. Visit Settings > Packages & Registries on the sidebar & then append /cleanup_image_tags to the URL to visit cleanup page
  5. Should be able to modify the settings & not see any errors.
  6. Verify The container registry clean up page allow savi... (#371882 - closed)
  7. Clicking on Save changes should redirect to settings page & show success alert
  8. Clicking on Cancel should redirect to settings 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.

Related to #363426 (closed)

Closes #371882 (closed)

Edited by Rahul Chanila

Merge request reports

Loading