From 32f2d406c3622bad5551356dceedd46ff6f38e92 Mon Sep 17 00:00:00 2001 From: YunaiV Date: Mon, 24 Feb 2025 23:06:56 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=E3=80=90=E4=BB=A3=E7=A0=81=E8=AF=84?= =?UTF-8?q?=E5=AE=A1=E3=80=91BPM=EF=BC=9A=E5=AD=90=E6=B5=81=E7=A8=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/nodes-config/ChildProcessNodeConfig.vue | 15 ++++++++------- .../src/nodes/ChildProcessNode.vue | 2 ++ .../create/ProcessDefinitionDetail.vue | 2 +- 3 files changed, 11 insertions(+), 8 deletions(-) diff --git a/src/components/SimpleProcessDesignerV2/src/nodes-config/ChildProcessNodeConfig.vue b/src/components/SimpleProcessDesignerV2/src/nodes-config/ChildProcessNodeConfig.vue index a7d9aee6..b6813444 100644 --- a/src/components/SimpleProcessDesignerV2/src/nodes-config/ChildProcessNodeConfig.vue +++ b/src/components/SimpleProcessDesignerV2/src/nodes-config/ChildProcessNodeConfig.vue @@ -28,11 +28,7 @@
- + 添加一行 + 添加一行 + 同主流程发起人 @@ -213,6 +211,7 @@ import { getForm } from '@/api/bpm/form' import { SimpleFlowNode, NodeType } from '../consts' import { useWatchNode, useDrawer, useNodeName, useFormFieldsAndStartUser } from '../node' import { parseFormFields } from '@/components/FormCreate/src/utils' + defineOptions({ name: 'ChildProcessNodeConfig' }) @@ -264,6 +263,7 @@ const saveConfig = async () => { if (!formRef) return false const valid = await formRef.value.validate() if (!valid) return false + // TODO @lesan:这里的 option 黄色告警,也处理下哈 const childInfo = childProcessOptions.value.find( (option) => option.key === configForm.value.calledProcessDefinitionKey ) @@ -286,11 +286,11 @@ const saveConfig = async () => { return true } // 显示子流程节点配置, 由父组件传过来 +// TODO @lesan:inVariables、outVariables 红色告警 const showChildProcessNodeConfig = (node: SimpleFlowNode) => { nodeName.value = node.name if (node.childProcessSetting) { - configForm.value.async = - node.childProcessSetting.async + configForm.value.async = node.childProcessSetting.async configForm.value.calledProcessDefinitionKey = node.childProcessSetting.calledProcessDefinitionKey configForm.value.skipStartUserNode = node.childProcessSetting.skipStartUserNode @@ -305,6 +305,7 @@ const showChildProcessNodeConfig = (node: SimpleFlowNode) => { defineExpose({ openDrawer, showChildProcessNodeConfig }) // 暴露方法给父组件 +// TODO @lesan:这里的 arr 黄色告警,也处理下哈,可以用 cursor quick fix 哈 const addVariable = (arr) => { arr.push({ source: '', diff --git a/src/components/SimpleProcessDesignerV2/src/nodes/ChildProcessNode.vue b/src/components/SimpleProcessDesignerV2/src/nodes/ChildProcessNode.vue index 987f0949..0b362446 100644 --- a/src/components/SimpleProcessDesignerV2/src/nodes/ChildProcessNode.vue +++ b/src/components/SimpleProcessDesignerV2/src/nodes/ChildProcessNode.vue @@ -66,6 +66,7 @@ import { SimpleFlowNode, NodeType, NODE_DEFAULT_TEXT } from '../consts' import NodeHandler from '../NodeHandler.vue' import { useNodeName2, useWatchNode, useTaskStatusClass } from '../node' import ChildProcessNodeConfig from '../nodes-config/ChildProcessNodeConfig.vue' + defineOptions({ name: 'ChildProcessNode' }) @@ -86,6 +87,7 @@ const currentNode = useWatchNode(props) // 节点名称编辑 const { showInput, blurEvent, clickTitle } = useNodeName2(currentNode, NodeType.CHILD_PROCESS_NODE) const nodeSetting = ref() + // 打开节点配置 const openNodeConfig = () => { if (readonly) { diff --git a/src/views/bpm/processInstance/create/ProcessDefinitionDetail.vue b/src/views/bpm/processInstance/create/ProcessDefinitionDetail.vue index 04f1d0a1..5944c253 100644 --- a/src/views/bpm/processInstance/create/ProcessDefinitionDetail.vue +++ b/src/views/bpm/processInstance/create/ProcessDefinitionDetail.vue @@ -157,7 +157,7 @@ const initProcessInfo = async (row: any, formVariables?: any) => { } /** 预测流程节点会因为输入的参数值而产生新的预测结果值,所以需重新预测一次 */ -// TODO @芋艿:这里我执行填写表单的时候不知道为啥一直报错,先注释了 +// TODO @芋艿:这里我执行填写表单的时候不知道为啥一直报错,先注释了 @lesan:可以和群里的小北说下 // watch( // detailForm.value, // (newValue) => { From d9019c127125d268ed645df45df3362a38a15aeb Mon Sep 17 00:00:00 2001 From: YunaiV Date: Mon, 24 Feb 2025 23:11:18 +0800 Subject: [PATCH 2/3] =?UTF-8?q?=E3=80=90=E4=BB=A3=E7=A0=81=E8=AF=84?= =?UTF-8?q?=E5=AE=A1=E3=80=91BPM=EF=BC=9A=E8=A7=A6=E5=8F=91=E5=99=A8=20HTT?= =?UTF-8?q?P=20=E5=BC=82=E6=AD=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../SimpleProcessDesignerV2/src/consts.ts | 14 ++++++++------ .../src/nodes-config/TriggerNodeConfig.vue | 8 +++++--- 2 files changed, 13 insertions(+), 9 deletions(-) diff --git a/src/components/SimpleProcessDesignerV2/src/consts.ts b/src/components/SimpleProcessDesignerV2/src/consts.ts index 1c36df02..5537142a 100644 --- a/src/components/SimpleProcessDesignerV2/src/consts.ts +++ b/src/components/SimpleProcessDesignerV2/src/consts.ts @@ -756,6 +756,7 @@ export enum TriggerTypeEnum { * 发送 HTTP 请求触发器 */ HTTP_REQUEST = 1, + // TODO @jason:要不把 FORM_UPDATE、FORM_DELETE 调整从 10、11 这样? /** * 表单数据更新触发器 */ @@ -764,6 +765,7 @@ export enum TriggerTypeEnum { * 表单数据删除触发器 */ FORM_DELETE = 3, + // TODO @jason:1)HTTP_REQUEST_ASYNC 这个枚举值?;2)枚举值改成 2?;3)【有点纠结,微信讨论】异步是里面加个属性 async 属性,还是作为单独的枚举值。 /** * 发起异步 HTTP 请求 */ @@ -795,7 +797,7 @@ export type FormTriggerSetting = { // 条件组 conditionGroups?: ConditionGroup // 更新表单字段配置 - updateFormFields?: Record, + updateFormFields?: Record // 删除表单字段配置 deleteFields?: string[] } @@ -813,11 +815,11 @@ export const TRIGGER_TYPES: DictDataVO[] = [ export type ChildProcessSetting = { calledProcessDefinitionKey: string calledProcessDefinitionName: string - async: boolean, - inVariables?: IOParameter[], - outVariables?: IOParameter[], - skipStartUserNode: boolean, - startUserSetting: StartUserSetting, + async: boolean + inVariables?: IOParameter[] + outVariables?: IOParameter[] + skipStartUserNode: boolean + startUserSetting: StartUserSetting } export type IOParameter = { diff --git a/src/components/SimpleProcessDesignerV2/src/nodes-config/TriggerNodeConfig.vue b/src/components/SimpleProcessDesignerV2/src/nodes-config/TriggerNodeConfig.vue index cb1b0727..29e9eea0 100644 --- a/src/components/SimpleProcessDesignerV2/src/nodes-config/TriggerNodeConfig.vue +++ b/src/components/SimpleProcessDesignerV2/src/nodes-config/TriggerNodeConfig.vue @@ -36,6 +36,7 @@ +