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

附件库支持按文件类型过滤 #5054

Closed
Roozenlz opened this issue Dec 17, 2023 · 3 comments · Fixed by #5893
Closed

附件库支持按文件类型过滤 #5054

Roozenlz opened this issue Dec 17, 2023 · 3 comments · Fixed by #5893
Assignees
Labels
area/core Issues or PRs related to the Halo Core kind/feature Categorizes issue or PR as related to a new feature.
Milestone

Comments

@Roozenlz
Copy link
Contributor

你当前使用的版本

2.11.2

描述一下此特性

附件库的查询接口提供按文件类型过滤的参数,支持后台查看文件时按照类型如视频、图片、压缩包等类型过滤查看,同时主题也能在前台根据查询接口按类型展示附件,目前仅能展示所有类型的文件,主题端想让用户选择附件库中的图片却会显示出其他类型的文件,不太合适。

附加信息

No response

@ruibaby
Copy link
Member

ruibaby commented Dec 18, 2023

/kind feature
/area core

@f2c-ci-robot f2c-ci-robot bot added kind/feature Categorizes issue or PR as related to a new feature. area/core Issues or PRs related to the Halo Core labels Dec 18, 2023
@guqing
Copy link
Member

guqing commented May 9, 2024

/milestone 2.16.x

@LIlGG
Copy link
Member

LIlGG commented May 10, 2024

/assign

f2c-ci-robot bot pushed a commit that referenced this issue May 16, 2024
…#5893)

#### What type of PR is this?

/kind feature
/area core
/area ui

#### What this PR does / why we need it:

为 `/apis/api.console.halo.run/v1alpha1/attachments` 接口增加了 `accepts` 可选参数,用于根据附件的 `MediaType` 进行筛选。

为附件库增加通过文件的 MediaType 类型进行筛选的筛选项。

同时支持使用了 `CoreSelectorProvider` 组件的文件选择框的筛选。现在只会显示 `accepts` 所支持的文件。

#### How to test it?

测试 ui 端文件选择框的类型筛选是否正确有效。
测试使用了 `CoreSelectorProvider` 组件的 `accepts` 是否有效。

#### Which issue(s) this PR fixes:

Fixes #5054

#### Does this PR introduce a user-facing change?
```release-note
附件库支持按文件类型进行过滤
```
@ruibaby ruibaby modified the milestones: 2.16.x, 2.16.0 May 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/core Issues or PRs related to the Halo Core kind/feature Categorizes issue or PR as related to a new feature.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants