Skip to content

Adds page URL params for container image tags list pagination

What does this MR do and why?

Uses persisted_pagination component (added in !127750 (merged)) to render pagination instead of registry-list

Hides pagination during delete mutation. This fix has been added to images list page as well

Adds tests

Fixes @gitlab/vue-no-new-non-primitive-in-template eslint warning

Screenshots or screen recordings

Before After
Pagination is not persisted in the URL Screen_Recording_2023-08-02_at_12.24.37_pm

How to set up and validate locally

  1. Setup & enable Container Registry https://gitlab.com/gitlab-org/gitlab-development-kit/-/blob/main/doc/howto/registry.md

  2. Follow steps in https://gitlab.com/gitlab-org/ci-cd/package-stage/package/-/wikis/Packages-Tips-&-Tricks#how-to-add-images-with-tags-quickly-to-the-registry

  3. To see pagination, run the following in the terminal

    $ ./publish.sh <project-path> 25 15 127.0.0.1:5000 # creates 15 images with 25 tags each
  4. Visit the container registry image list page in group & project view

  5. Visit one of the tags published.

Validation

  1. Pagination should work & url should be updated.
  2. Refreshing the page with pagination should show the same list
  3. Searching/Sorting should reset pagination URL params.
  4. Deleting/bulk-deleting tag(s) should hide pagination.
  5. On the container registry image list page, deleting an image should hide pagination.

MR acceptance checklist

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

Closes #416931 (closed)

Edited by Rahul Chanila

Merge request reports