Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

on-prem add blueprint pagination and fix filtering (HMS-5306) #2739

Merged

Conversation

kingsleyzissou
Copy link
Collaborator

@kingsleyzissou kingsleyzissou commented Jan 13, 2025

This PR adds pagination support for on-prem blueprints and fixes the filtering of blueprints
when trying to search for blueprints.

/jira-epic COMPOSER-2411

JIRA: HMS-5306

@schutzbot schutzbot changed the title on-prem add blueprint pagination and fix filtering on-prem add blueprint pagination and fix filtering (HMS-5306) Jan 13, 2025
@kingsleyzissou kingsleyzissou force-pushed the cockpit_blueprint_pagination branch from 39696f9 to 041fd72 Compare January 13, 2025 09:39
Copy link

codecov bot commented Jan 13, 2025

Codecov Report

Attention: Patch coverage is 3.84615% with 25 lines in your changes missing coverage. Please review.

Project coverage is 84.65%. Comparing base (52efa80) to head (1e08b22).

Files with missing lines Patch % Lines
src/store/cockpitApi.ts 3.84% 25 Missing ⚠️

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #2739      +/-   ##
==========================================
- Coverage   84.73%   84.65%   -0.09%     
==========================================
  Files         186      186              
  Lines       20955    20975      +20     
  Branches     2033     2033              
==========================================
  Hits        17756    17756              
- Misses       3177     3197      +20     
  Partials       22       22              
Files with missing lines Coverage Δ
src/store/cockpitApi.ts 25.25% <3.84%> (-6.40%) ⬇️

Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 52efa80...1e08b22. Read the comment docs.

@kingsleyzissou kingsleyzissou force-pushed the cockpit_blueprint_pagination branch from 79ed0c7 to 53f5d77 Compare January 15, 2025 18:08
@lucasgarfield lucasgarfield force-pushed the cockpit_blueprint_pagination branch from 53f5d77 to 32384b9 Compare January 16, 2025 22:41
@kingsleyzissou kingsleyzissou marked this pull request as ready for review January 17, 2025 10:25
@lucasgarfield lucasgarfield force-pushed the cockpit_blueprint_pagination branch from 32384b9 to 1e08b22 Compare January 17, 2025 13:02
The blueprint list wasn't being filtered correctly if the blueprint
name was specified or if any search terms were provided. This commit
fixes that.
Use the filename/id of the blueprints as the links to
the first and last element for the blueprint list metadata.
These links are a little meaningless since they should be
urls.
Add blueprint list pagination support
Get rid of the `Math.floor` for the version and just ensure that
the version is a number.
@lucasgarfield lucasgarfield force-pushed the cockpit_blueprint_pagination branch from 1e08b22 to 2b3db57 Compare January 17, 2025 15:49
Copy link
Collaborator

@lucasgarfield lucasgarfield left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've tested, working nicely.

We do have a new filtering utility function we could use for enhancing the search a bit (maybe) but that can be follow-up since other PRs depend on this.

@lucasgarfield lucasgarfield enabled auto-merge (rebase) January 17, 2025 16:27
@lucasgarfield lucasgarfield merged commit 8d34f85 into osbuild:main Jan 17, 2025
6 of 16 checks passed
@kingsleyzissou kingsleyzissou deleted the cockpit_blueprint_pagination branch February 5, 2025 12:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants