You've already forked DataMate
feat(annotation): 完善文件版本管理和标注同步功能
- 将 useNewVersionUsingPost 重命名为 applyNewVersionUsingPost - 添加 fileVersionCheckSeqRef 避免版本检查竞态条件 - 移除 checkingFileVersion 状态变量的渲染依赖 - 在文件版本信息中添加 annotationVersionUnknown 字段 - 修复前端文件版本比较显示的 JSX 语法 - 添加历史标注缺少版本信息的提示显示 - 配置 Alembic 异步数据库迁移环境支持 aiomysql - 添加文件版本未知状态的后端判断逻辑 - 实现标注清除时的段落注释清理功能 - 添加知识库同步钩子到版本更新流程
This commit is contained in:
@@ -104,6 +104,7 @@ export interface FileVersionCheckResponse {
|
||||
fileId: string;
|
||||
currentFileVersion: number;
|
||||
annotationFileVersion: number | null;
|
||||
annotationVersionUnknown: boolean;
|
||||
hasNewVersion: boolean;
|
||||
}
|
||||
|
||||
@@ -118,7 +119,7 @@ export interface UseNewVersionResponse {
|
||||
message: string;
|
||||
}
|
||||
|
||||
export function useNewVersionUsingPost(projectId: string, fileId: string) {
|
||||
export function applyNewVersionUsingPost(projectId: string, fileId: string) {
|
||||
return post(`/api/annotation/editor/projects/${projectId}/files/${fileId}/use-new-version`, {});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user