新增渠道批量导入密钥, 密钥重试功能, 分组模型置顶/置底功能#205
Open
showyourlucky wants to merge 22 commits intobestruirui:devfrom
Open
Conversation
2. 渠道界面分页展示api key
- 新增多Key重试功能,支持轮询和随机两种负载均衡策略 - 新增自动禁用Key功能,可配置连续失败阈值 - 修改RecordFailure函数返回当前连续失败次数 - 更新前后端数据模型、API接口和UI表单
* 引入全新的 `ModelSelector` 组件,支持基于复选框的模型选择机制。 * 创建了 `ModelCheckboxItem`、`ModelInput` 和 `ModelSelectorHeader` 等子组件,以构建完整的功能模块。 * 集成了来自 `@radix-ui/react-checkbox` 的复选框UI组件,以提供标准化的交互体验。 * 实现了模型搜索、刷新及批量清除功能,提升用户操作效率。 * 为模型选择器提供了完善的国际化(i18n)支持,涵盖英语、简体中文和繁体中文,以适应不同地区用户。 * 更新了 `BatchImportModal` 和 `Form` 组件,以无缝集成新的选择器,优化工作流程。 * 同时支持通过 API 获取和手动添加的模型,并加以视觉区分,使用户一目了然。 * 为模型名称新增了复制到剪贴板的功能,方便快速引用。 * 增设了清空所有模型的确认对话框,确保操作的严谨性。
* **开放接口**:导出 `ChannelRefreshCacheByID` 函数,确保批量导入完成后可即时触发缓存刷新。 * **自动更新**:在批量导入任务顺利执行后,系统将自动刷新相关的渠道缓存。 * **批量操作**:在模型选择器中引入“全选”按钮。 * **精准导航**:在批量导入结果页新增分页输入框,支持用户通过输入页码直接跳转。 * **交互优化**:分页跳转支持 Enter(回车键)确认,操作更加符合用户习惯。 * **类型定义**:更新批量导入状态的响应类型,允许错误信息及重复项数组在无数据时返回 null。
This reverts commit eeba2c1.
Owner
|
感谢PR
真正使用的模型是分组中设置的,添加渠道时,直接全部添加就行,而且你这样选择,如果打开自动同步的话,同步一次后就会把这些全都覆盖了,真的需要限制模型,应该使用正则 |
This reverts commit c0ada74. # Conflicts: # web/package.json # web/pnpm-lock.yaml # web/public/locale/en.json # web/public/locale/zh_hans.json # web/public/locale/zh_hant.json # web/src/components/modules/channel/BatchImportModal.tsx # web/src/components/modules/channel/Form.tsx # web/src/components/modules/channel/ModelSelector/ModelCheckboxItem.tsx # web/src/components/modules/channel/ModelSelector/ModelSelectorHeader.tsx # web/src/components/modules/channel/ModelSelector/index.tsx # web/src/components/modules/channel/ModelSelector/types.ts
Author
之前没搞懂这个自动同步, 本来想的是两边都可以做筛选
相关代码已经回滚 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
重新提交下pr, 辛苦下佬审核下代码