From f5711a12120f472d57a6b419b010e19e814a7284 Mon Sep 17 00:00:00 2001 From: zhanghao <774378400@qq.com> Date: Wed, 22 Jul 2026 15:59:26 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E8=B0=83=E6=95=B4=E8=8A=82=E7=82=B9?= =?UTF-8?q?=E5=BC=95=E7=94=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/params/BasicNodeParams.vue | 2 +- .../flow/components/params/CodeNodeParams.vue | 2 +- .../flow/components/params/HttpNodeParams.vue | 8 ++-- .../components/params/SdAgentNodeParams.vue | 5 ++- src/views/flow/config.js | 38 +++++++++++++++++++ src/views/flow/index.vue | 2 +- 6 files changed, 48 insertions(+), 9 deletions(-) diff --git a/src/views/flow/components/params/BasicNodeParams.vue b/src/views/flow/components/params/BasicNodeParams.vue index f41c34e..ee8eef7 100644 --- a/src/views/flow/components/params/BasicNodeParams.vue +++ b/src/views/flow/components/params/BasicNodeParams.vue @@ -11,7 +11,7 @@
- 获取位置 + 获取位置
diff --git a/src/views/flow/components/params/CodeNodeParams.vue b/src/views/flow/components/params/CodeNodeParams.vue index 6443d53..cbd1829 100644 --- a/src/views/flow/components/params/CodeNodeParams.vue +++ b/src/views/flow/components/params/CodeNodeParams.vue @@ -119,7 +119,7 @@ @visible-change=" (visible) => visibleChange(visible, index, property.quote) " - @change="(value) => cascaderChange(value, index)" + @change="(value) => cascaderChange(value, index, formData, 'nodeParams')" /> diff --git a/src/views/flow/components/params/HttpNodeParams.vue b/src/views/flow/components/params/HttpNodeParams.vue index e817440..761d62d 100644 --- a/src/views/flow/components/params/HttpNodeParams.vue +++ b/src/views/flow/components/params/HttpNodeParams.vue @@ -56,7 +56,7 @@ " v-model="property.quote" :checkStrictly="true" :options="quoteOptions" placeholder="请选择" @visible-change=" (visible) => visibleChange(visible, index, property.quote) - " @change="(value) => cascaderChange(value, index)" /> + " @change="(value) => cascaderChange(value, index, httpNodeData, 'config')" /> @@ -120,7 +120,7 @@ " v-model="property.quote" :checkStrictly="true" :options="quoteOptions" placeholder="请选择" @visible-change=" (visible) => visibleChange(visible, index, property.quote) - " @change="(value) => cascaderChange(value, index)" /> + " @change="(value) => cascaderChange(value, index, httpNodeData, 'headers')" /> + " @change="(value) => cascaderChange(value, index, httpNodeData, 'params')" /> diff --git a/src/views/flow/components/params/SdAgentNodeParams.vue b/src/views/flow/components/params/SdAgentNodeParams.vue index f6969e6..749fa9c 100644 --- a/src/views/flow/components/params/SdAgentNodeParams.vue +++ b/src/views/flow/components/params/SdAgentNodeParams.vue @@ -46,7 +46,7 @@ " v-model="property.quote" :checkStrictly="true" :options="quoteOptions" placeholder="请选择" @visible-change=" (visible) => visibleChange(visible, index, property.quote) - " @change="(value) => cascaderChange(value, index, 'sdAgentConfig')" /> + " @change="(value) => cascaderChange(value, index, sdAgentNodeData, 'config')" /> @@ -99,7 +99,7 @@ " v-model="property.quote" :checkStrictly="true" :options="quoteOptions" placeholder="请选择" @visible-change=" (visible) => visibleChange(visible, index, property.quote) - " @change="(value) => cascaderChange(value, index, 'sdAgentTts')" /> + " @change="(value) => cascaderChange(value, index, sdAgentNodeData, 'tts')" /> @@ -230,6 +230,7 @@ const initData = () => { ...transformedData, outputParams }; + console.log('sdAgentNodeData', sdAgentNodeData.value) } watch( diff --git a/src/views/flow/config.js b/src/views/flow/config.js index b7127c3..39db4fa 100644 --- a/src/views/flow/config.js +++ b/src/views/flow/config.js @@ -157,6 +157,16 @@ const voiceOptions = () => { }] } +const inspectionEventTypes = () => { + return [{ + value: 'No-Glove', + label: '没戴手套' + }, { + value: 'No-Helmet-Glove', + label: '没戴头盔' + }] +} + export const collapseList = [ { collapseTitle: "相机", @@ -398,6 +408,34 @@ function handler(params) { ], outputType: 'json' }, + { + icon: cameraSvg, + name: "开始监听报警事件", + type: "serviceNode", + desc: "开始监听报警事件", + action: 'INSPECTION_ALERT_LISTEN_START', + nodeType: 'EDGE', + nodeParams: [ + { name: "terminalId", type: "input", input: "", disabled: true }, + { name: "eventTypes", type: "input", input: "", componentType: 'select', selectOptions: inspectionEventTypes(), disabled: true } + ], + outputParams: [], + outputType: 'json' + }, + { + icon: cameraSvg, + name: "结束监听报警事件", + type: "serviceNode", + desc: "结束监听报警事件", + action: 'INSPECTION_ALERT_LISTEN_STOP', + nodeType: 'EDGE', + nodeParams: [ + { name: "terminalId", type: "input", input: "", disabled: true }, + { name: "eventTypes", type: "input", input: "", componentType: 'select', selectOptions: inspectionEventTypes(), disabled: true } + ], + outputParams: [], + outputType: 'json' + }, ], }, { diff --git a/src/views/flow/index.vue b/src/views/flow/index.vue index 56a7cf0..7aed4c0 100644 --- a/src/views/flow/index.vue +++ b/src/views/flow/index.vue @@ -635,7 +635,7 @@ const initFlow = () => { lf.on("node:dbclick", ({ data, e }) => { if ( - ["selectArea", "branch", "stopLoop", "subStart", "subEnd"].includes(data.type) + ["selectArea", "branch", "stopLoop", "subStart", "subEnd", "end"].includes(data.type) ) { return; }