Add files via upload

This commit is contained in:
公明
2026-07-14 15:11:50 +08:00
committed by GitHub
parent a496bd7aee
commit 2924d6636c
8 changed files with 44 additions and 44 deletions
+2 -2
View File
@@ -332,7 +332,7 @@ const responseStreamStateByProgressId = new Map();
// 主通道当前迭代轮次缓存:progressId -> { iteration, orchestration }
const mainIterationStateByProgressId = new Map();
/** 图编排多 Agent 节点切换时清空流式聚合,避免推理/输出条目覆盖上一节点内容 */
/** 工作流多 Agent 节点切换时清空流式聚合,避免推理/输出条目覆盖上一节点内容 */
function clearTimelineStreamStates(progressId) {
responseStreamStateByProgressId.delete(progressId);
thinkingStreamStateByProgressId.delete(progressId);
@@ -1886,7 +1886,7 @@ function handleStreamEvent(event, progressElement, progressId,
workflowNodeId: curNode,
einoAgent: curAgent
});
// 主通道进入新轮次或图编排切换到新 Agent 节点后,不复用上一段的流式时间线条目
// 主通道进入新轮次或工作流切换到新 Agent 节点后,不复用上一段的流式时间线条目
if (prevN != null && (n < prevN || prevN !== n || (curNode && prevNode && curNode !== prevNode))) {
clearTimelineStreamStates(progressId);
}
+1 -1
View File
@@ -76,7 +76,7 @@
}
async function createInspection(apiFetch, file) {
if (!file) throw new WorkflowPackageError('WFPKG_FILE_REQUIRED', '请选择本地图编排包');
if (!file) throw new WorkflowPackageError('WFPKG_FILE_REQUIRED', '请选择本地工作流包');
const body = new FormData();
body.append('file', file, file.name || 'workflow.csapkg.zip');
const response = await apiFetch('/api/workflow-package-inspections', { method: 'POST', body: body });
+2 -2
View File
@@ -2,11 +2,11 @@ const fs = require('node:fs');
const test = require('node:test');
const assert = require('node:assert/strict');
test('图编排提供导入、导出和覆盖确认容器', () => {
test('工作流提供导入、导出和覆盖确认容器', () => {
const html = fs.readFileSync('web/templates/index.html', 'utf8');
const zh = JSON.parse(fs.readFileSync('web/static/i18n/zh-CN.json', 'utf8'));
assert.match(html, /onclick="openWorkflowPackageImportModal\(\)"/);
assert.match(html, /onclick="exportCurrentWorkflowPackage\(\)"/);
assert.match(html, /onclick="[^"]*exportCurrentWorkflowPackage\(\)"/);
assert.match(html, /id="workflow-package-import-modal"/);
assert.match(html, /id="workflow-package-overwrite-modal"/);
assert.equal(zh.workflows.package.importLocal, '导入本地包');