feat:执行过程编排页面重构及删除功能新增

This commit is contained in:
liailing1026
2026-03-03 09:56:58 +08:00
parent f0f0d5bdcd
commit 2be5a5a454
5 changed files with 739 additions and 336 deletions

View File

@@ -310,6 +310,26 @@ export const useSelectionStore = defineStore('selection', () => {
return result
}
/**
* 从数据库删除指定分支
* @param TaskID 大任务ID数据库主键
* @param stepId 小任务ID
* @param branchId 要删除的分支ID
* @returns Promise<boolean> 是否删除成功
*/
async function deleteTaskProcessBranchFromDB(
TaskID: string,
stepId: string,
branchId: string,
): Promise<boolean> {
// 导入 api避免循环导入问题
const { default: api } = await import('@/api')
const result = await api.deleteTaskProcessBranch(TaskID, stepId, branchId)
return result
}
/**
* 从数据库恢复任务过程分支数据
* @param dbBranches 从数据库读取的任务过程分支数据
@@ -676,6 +696,7 @@ export const useSelectionStore = defineStore('selection', () => {
saveBranchesToDB,
restoreAgentCombinationsFromDB,
saveTaskProcessBranchesToDB,
deleteTaskProcessBranchFromDB,
restoreTaskProcessBranchesFromDB,
}
})