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

Support sort parameter when listing extensions #4274

Merged

Conversation

JohnNiang
Copy link
Member

What type of PR is this?

/kind feature
/area core

What this PR does / why we need it:

Currently, we cannot pass a sort parameter into extensions' list API, so the result of the API is unsortable.

This PR add the support for that API. e.g.:

curl -X 'GET' \
  'http://localhost:8090/api/v1alpha1/annotationsettings?sort=metadata.name,desc' \
  -H 'accept: */*'

Does this PR introduce a user-facing change?

Extension 查询接口支持排序参数。

@f2c-ci-robot f2c-ci-robot bot added release-note Denotes a PR that will be considered when it comes time to generate release notes. kind/feature Categorizes issue or PR as related to a new feature. labels Jul 21, 2023
@f2c-ci-robot f2c-ci-robot bot requested review from ruibaby and wan92hen July 21, 2023 07:41
@f2c-ci-robot f2c-ci-robot bot added the area/core Issues or PRs related to the Halo Core label Jul 21, 2023
@codecov
Copy link

codecov bot commented Jul 21, 2023

Codecov Report

Merging #4274 (77ddc6a) into main (617d05f) will decrease coverage by 0.17%.
The diff coverage is 100.00%.

@@             Coverage Diff              @@
##               main    #4274      +/-   ##
============================================
- Coverage     60.30%   60.13%   -0.17%     
+ Complexity     2423     2407      -16     
============================================
  Files           366      364       -2     
  Lines         12617    12584      -33     
  Branches        906      903       -3     
============================================
- Hits           7609     7568      -41     
- Misses         4566     4575       +9     
+ Partials        442      441       -1     
Impacted Files Coverage Δ
...halo/app/theme/endpoint/CategoryQueryEndpoint.java 98.48% <ø> (ø)
...a/run/halo/app/theme/endpoint/PostPublicQuery.java 100.00% <ø> (ø)
...lo/app/theme/endpoint/SinglePageQueryEndpoint.java 100.00% <ø> (ø)
.../run/halo/app/theme/endpoint/TagQueryEndpoint.java 59.37% <ø> (ø)
...alo/app/extension/router/ExtensionListHandler.java 100.00% <100.00%> (ø)
...tension/router/ExtensionRouterFunctionFactory.java 100.00% <100.00%> (ø)

... and 7 files with indirect coverage changes

Copy link
Member

@ruibaby ruibaby left a comment

Choose a reason for hiding this comment

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

/lgtm

@f2c-ci-robot f2c-ci-robot bot added the lgtm Indicates that a PR is ready to be merged. label Jul 24, 2023
@ruibaby
Copy link
Member

ruibaby commented Jul 24, 2023

/hold

Signed-off-by: Ryan Wang <i@ryanc.cc>
@ruibaby
Copy link
Member

ruibaby commented Jul 24, 2023

/unhold

Copy link
Member

@ruibaby ruibaby left a comment

Choose a reason for hiding this comment

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

/lgtm

@f2c-ci-robot f2c-ci-robot bot added do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. lgtm Indicates that a PR is ready to be merged. and removed lgtm Indicates that a PR is ready to be merged. labels Jul 24, 2023
@f2c-ci-robot
Copy link

f2c-ci-robot bot commented Jul 24, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: ruibaby

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

1 similar comment
@f2c-ci-robot
Copy link

f2c-ci-robot bot commented Jul 24, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: ruibaby

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@f2c-ci-robot f2c-ci-robot bot added approved Indicates a PR has been approved by an approver from all required OWNERS files. labels Jul 24, 2023
@ruibaby ruibaby removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jul 24, 2023
@f2c-ci-robot f2c-ci-robot bot merged commit fdfaa53 into halo-dev:main Jul 24, 2023
4 checks passed
@JohnNiang JohnNiang deleted the feat/support-sort-param-when-listing-exts branch July 24, 2023 07:22
@ruibaby ruibaby added this to the 2.8.0 milestone Jul 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. area/core Issues or PRs related to the Halo Core kind/feature Categorizes issue or PR as related to a new feature. lgtm Indicates that a PR is ready to be merged. release-note Denotes a PR that will be considered when it comes time to generate release notes.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants