@nocobase/plugin-workflow 2.1.11 → 2.2.0-alpha.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/client-v2.d.ts +2 -0
- package/client-v2.js +1 -0
- package/dist/client/119.e7dbd037d52d1286.js +10 -0
- package/dist/client/142.d84a976875799df4.js +10 -0
- package/dist/client/159.3d5abee06b818db3.js +10 -0
- package/dist/client/276.69fb2aea13bc7c37.js +10 -0
- package/dist/client/346.66d060d37843d3d1.js +10 -0
- package/dist/client/382.80ebd002a9971b65.js +10 -0
- package/dist/client/394.d7eacf666590a6ae.js +10 -0
- package/dist/client/438.c4de8f085e490158.js +10 -0
- package/dist/client/509.2f72dd97808f12d1.js +10 -0
- package/dist/client/54.c452a382e9b3953d.js +10 -0
- package/dist/client/{618.c91be3f6e4d73501.js → 618.a97bc812678ab2a7.js} +1 -1
- package/dist/client/635.3f165e9ed7e940b2.js +10 -0
- package/dist/client/67.4117e04bd42f9d42.js +10 -0
- package/dist/client/719.5801e3f1cf81b97b.js +10 -0
- package/dist/client/739.955f18b3dc31ae3a.js +10 -0
- package/dist/client/759.13aab01e6912ed8d.js +10 -0
- package/dist/client/772.1ebaef11a0ac8688.js +10 -0
- package/dist/client/782.332fd345a98b82c2.js +10 -0
- package/dist/client/828.77de843c49fb307a.js +10 -0
- package/dist/client/87.d2c2b5b1cae08bfc.js +10 -0
- package/dist/client/938.77649c32dae1c225.js +10 -0
- package/dist/client/964.cb1ecff7a46687b7.js +10 -0
- package/dist/client/972.4da2796f3f2df874.js +10 -0
- package/dist/client/AddNodeContext.d.ts +1 -9
- package/dist/client/Branch.d.ts +1 -1
- package/dist/client/BranchContext.d.ts +2 -10
- package/dist/client/FlowContext.d.ts +10 -5
- package/dist/client/NodeClipboardContext.d.ts +12 -2
- package/dist/client/NodeDragContext.d.ts +14 -2
- package/dist/client/RemoveNodeContext.d.ts +16 -2
- package/dist/client/index.d.ts +1 -1
- package/dist/client/index.js +1 -1
- package/dist/client/nodeVariableUtils.d.ts +7 -6
- package/dist/client/nodes/calculation.d.ts +3 -75
- package/dist/client/nodes/condition.d.ts +7 -111
- package/dist/client/nodes/create.d.ts +3 -124
- package/dist/client/nodes/destroy.d.ts +2 -57
- package/dist/client/nodes/end.d.ts +2 -23
- package/dist/client/nodes/index.d.ts +2 -91
- package/dist/client/nodes/multi-conditions.d.ts +10 -48
- package/dist/client/nodes/output.d.ts +2 -44
- package/dist/client/nodes/query.d.ts +3 -255
- package/dist/client/nodes/update.d.ts +2 -117
- package/dist/client/style.d.ts +7 -27
- package/dist/client/triggers/collection.d.ts +3 -154
- package/dist/client/triggers/index.d.ts +2 -36
- package/dist/client/triggers/schedule/index.d.ts +8 -65
- package/dist/client/utils.d.ts +4 -5
- package/dist/client/variable.d.ts +4 -44
- package/dist/client-v2/119.81195bcd0d451279.js +10 -0
- package/dist/client-v2/142.3d386748090ff6d3.js +10 -0
- package/dist/client-v2/159.cb221540c286cd32.js +10 -0
- package/dist/client-v2/224.44a5e1227bee33fb.js +10 -0
- package/dist/client-v2/276.43297f402f31970e.js +10 -0
- package/dist/client-v2/326.bdc99ad8e7590970.js +10 -0
- package/dist/client-v2/346.8c038b3c99d4fdc9.js +10 -0
- package/dist/client-v2/382.05f5482bb512b179.js +10 -0
- package/dist/client-v2/387.ab3eac2eb447f36f.js +10 -0
- package/dist/client-v2/394.515ed058e7f72797.js +10 -0
- package/dist/client-v2/438.b7df0416b66f8f64.js +10 -0
- package/dist/client-v2/513.ab2bdd96ad9ece4d.js +10 -0
- package/dist/client-v2/54.287764bc467d65da.js +10 -0
- package/dist/client-v2/635.37de4abe241b30e8.js +10 -0
- package/dist/client-v2/719.05cf070ef89a78f4.js +10 -0
- package/dist/client-v2/739.906e94bbe6d52a3d.js +10 -0
- package/dist/client-v2/759.7b162ad3adf450f1.js +10 -0
- package/dist/client-v2/772.8e5148d8c1518449.js +10 -0
- package/dist/client-v2/938.717e47af39485b29.js +10 -0
- package/dist/client-v2/ExecutionCanvas.d.ts +15 -0
- package/dist/client-v2/canvas/AddNodeContext.d.ts +35 -0
- package/dist/client-v2/canvas/AddNodeContext.shared.d.ts +33 -0
- package/dist/client-v2/canvas/AddNodeSlot.d.ts +20 -0
- package/dist/client-v2/canvas/Branch.d.ts +32 -0
- package/dist/client-v2/canvas/BranchContext.d.ts +20 -0
- package/dist/client-v2/canvas/BranchRenderContext.d.ts +14 -0
- package/dist/client-v2/canvas/CanvasContent.d.ts +20 -0
- package/dist/client-v2/canvas/DownstreamBranchIndex.d.ts +20 -0
- package/dist/client-v2/canvas/Instruction.d.ts +139 -0
- package/dist/{client/triggers/schedule/EndsByField.d.ts → client-v2/canvas/JobButton.d.ts} +3 -3
- package/dist/client-v2/canvas/Node.d.ts +36 -0
- package/dist/client-v2/canvas/NodeClipboardContext.d.ts +64 -0
- package/dist/client-v2/canvas/NodeConfigDrawer.d.ts +27 -0
- package/dist/client-v2/canvas/NodeDragContext.d.ts +83 -0
- package/dist/client-v2/canvas/RemoveNodeContext.d.ts +45 -0
- package/dist/client-v2/canvas/WorkflowTypedVariableInput.d.ts +16 -0
- package/dist/client-v2/canvas/WorkflowVariableInput.d.ts +39 -0
- package/dist/client-v2/canvas/WorkflowVariableJsonTextArea.d.ts +15 -0
- package/dist/client-v2/canvas/WorkflowVariableTextArea.d.ts +18 -0
- package/dist/client-v2/canvas/adaptVariableOptionToMetaTree.d.ts +48 -0
- package/dist/client-v2/canvas/addNodeController.d.ts +70 -0
- package/dist/client-v2/canvas/collectionFieldOptions.d.ts +57 -0
- package/dist/client-v2/canvas/contexts.d.ts +84 -0
- package/dist/client-v2/canvas/dropImpact.d.ts +28 -0
- package/dist/client-v2/canvas/instructionAvailability.d.ts +26 -0
- package/dist/client-v2/canvas/nodeRenderDispatch.d.ts +79 -0
- package/dist/client-v2/canvas/nodeTree.d.ts +21 -0
- package/dist/client-v2/canvas/nodeVariableUtils.d.ts +14 -0
- package/dist/client-v2/canvas/removeNodeUtils.d.ts +31 -0
- package/dist/client-v2/canvas/style.d.ts +35 -0
- package/dist/client-v2/canvas/textAreaInsertion.d.ts +14 -0
- package/dist/client-v2/canvas/useWorkflowInstruction.d.ts +23 -0
- package/dist/client-v2/canvas/useWorkflowVariableOptions.d.ts +40 -0
- package/dist/client-v2/canvas/workflowVariableConverters.d.ts +13 -0
- package/dist/client-v2/components/Calculation.d.ts +18 -0
- package/dist/client-v2/components/ExecutionStatusIcon.d.ts +18 -0
- package/dist/{client/triggers/schedule/RepeatField.d.ts → client-v2/components/ExecutionStatusTag.d.ts} +3 -4
- package/dist/client-v2/components/ExecutionViewHeader.d.ts +29 -0
- package/dist/client-v2/components/ExecutionsDropdown.d.ts +25 -0
- package/dist/client-v2/components/FilterDynamicComponent.d.ts +22 -0
- package/dist/client-v2/components/HideVariableContext.d.ts +11 -0
- package/dist/client-v2/components/JobResultModal.d.ts +11 -0
- package/dist/client-v2/components/RadioWithTooltip.d.ts +23 -0
- package/dist/client-v2/components/SyncModeSelect.d.ts +16 -0
- package/dist/{client/triggers/schedule/OnField.d.ts → client-v2/components/SyncModeTag.d.ts} +3 -3
- package/dist/client-v2/components/TestRunButton.d.ts +36 -0
- package/dist/client-v2/components/TimeoutInput.d.ts +15 -0
- package/dist/client-v2/components/WorkflowCanvasHeader.d.ts +17 -0
- package/dist/client-v2/components/WorkflowDetailsModal.d.ts +25 -0
- package/dist/client-v2/components/WorkflowEnabledSwitch.d.ts +16 -0
- package/dist/client-v2/components/WorkflowMenu.d.ts +17 -0
- package/dist/client-v2/components/WorkflowRevisionsDropdown.d.ts +15 -0
- package/dist/client-v2/components/WorkflowVariableWrapper.d.ts +25 -0
- package/dist/client-v2/components/collection/AppendsSelect.d.ts +15 -0
- package/dist/client-v2/components/collection/AssignedFieldsEditor.d.ts +16 -0
- package/dist/client-v2/components/collection/CollectionCascader.d.ts +15 -0
- package/dist/client-v2/components/collection/FieldsSelect.d.ts +16 -0
- package/dist/client-v2/components/collection/PaginationFields.d.ts +14 -0
- package/dist/client-v2/components/collection/SortFieldsInput.d.ts +19 -0
- package/dist/client-v2/components/collection/TriggerCollectionRecordSelect.d.ts +15 -0
- package/dist/client-v2/components/collection/index.d.ts +16 -0
- package/dist/client-v2/components/collection/utils.d.ts +42 -0
- package/dist/client-v2/components/formatResultForDisplay.d.ts +17 -0
- package/dist/client-v2/components/jobStatus.d.ts +27 -0
- package/dist/client-v2/components/renderEngineReference.d.ts +10 -0
- package/dist/client-v2/components/workflowCanvas.d.ts +41 -0
- package/dist/client-v2/constants.d.ts +14 -0
- package/dist/client-v2/hooks/useWorkflowRuntimePaths.d.ts +37 -0
- package/dist/client-v2/index.d.ts +43 -0
- package/dist/client-v2/index.js +10 -0
- package/dist/client-v2/locale.d.ts +41 -0
- package/dist/{client → client-v2}/models/NodeDetailsGridModel.d.ts +1 -1
- package/dist/{client → client-v2}/models/NodeDetailsModel.d.ts +1 -1
- package/dist/{client → client-v2}/models/NodeValueModel.d.ts +1 -1
- package/dist/{client → client-v2}/models/TaskCardCommonItemModel.d.ts +1 -1
- package/dist/{client → client-v2}/models/index.d.ts +1 -0
- package/dist/client-v2/models/triggerWorkflows.d.ts +43 -0
- package/dist/client-v2/nodes/calculation.d.ts +38 -0
- package/dist/client-v2/nodes/collectionNode.d.ts +29 -0
- package/dist/client-v2/nodes/components/calculation.d.ts +11 -0
- package/dist/client-v2/nodes/components/collection.d.ts +15 -0
- package/dist/client-v2/nodes/components/condition.d.ts +25 -0
- package/dist/client-v2/nodes/components/conditionShared.d.ts +20 -0
- package/dist/client-v2/nodes/components/create.d.ts +12 -0
- package/dist/client-v2/nodes/components/destroy.d.ts +12 -0
- package/dist/{client/triggers/schedule/ScheduleConfig.d.ts → client-v2/nodes/components/end.d.ts} +1 -1
- package/dist/client-v2/nodes/components/filter.d.ts +16 -0
- package/dist/client-v2/nodes/components/multi-conditions.d.ts +13 -0
- package/dist/client-v2/nodes/components/multiConditionsShared.d.ts +20 -0
- package/dist/client-v2/nodes/components/output.d.ts +10 -0
- package/dist/client-v2/nodes/components/query.d.ts +12 -0
- package/dist/client-v2/nodes/components/update.d.ts +12 -0
- package/dist/client-v2/nodes/condition.d.ts +46 -0
- package/dist/client-v2/nodes/create.d.ts +30 -0
- package/dist/client-v2/nodes/destroy.d.ts +24 -0
- package/dist/client-v2/nodes/end.d.ts +21 -0
- package/dist/client-v2/nodes/multi-conditions.d.ts +34 -0
- package/dist/client-v2/nodes/output.d.ts +29 -0
- package/dist/client-v2/nodes/query.d.ts +32 -0
- package/dist/client-v2/nodes/update.d.ts +25 -0
- package/dist/client-v2/pages/ExecutionHistoryDrawer.d.ts +13 -0
- package/dist/client-v2/pages/ExecutionViewPage.d.ts +10 -0
- package/dist/client-v2/pages/WorkflowCanvasPage.d.ts +10 -0
- package/dist/client-v2/pages/WorkflowCategoryTabs.d.ts +25 -0
- package/dist/client-v2/pages/WorkflowFormDrawer.d.ts +39 -0
- package/dist/client-v2/pages/WorkflowPane.d.ts +10 -0
- package/dist/client-v2/plugin.d.ts +67 -0
- package/dist/client-v2/triggers/ExecuteWorkflowButton.d.ts +35 -0
- package/dist/client-v2/triggers/TriggerConfig.d.ts +22 -0
- package/dist/client-v2/triggers/TriggerExecutionButton.d.ts +13 -0
- package/dist/client-v2/triggers/collection/CollectionConfig.d.ts +14 -0
- package/dist/client-v2/triggers/collection/TriggerCollectionConfig.d.ts +11 -0
- package/dist/client-v2/triggers/collection/constants.d.ts +28 -0
- package/dist/client-v2/triggers/collection/index.d.ts +40 -0
- package/dist/client-v2/triggers/index.d.ts +61 -0
- package/dist/client-v2/triggers/schedule/EndsByField.d.ts +17 -0
- package/dist/client-v2/triggers/schedule/OnField.d.ts +20 -0
- package/dist/client-v2/triggers/schedule/RepeatField.d.ts +23 -0
- package/dist/client-v2/triggers/schedule/ScheduleConfig.d.ts +17 -0
- package/dist/client-v2/triggers/schedule/ScheduleModes.d.ts +41 -0
- package/dist/{client → client-v2}/triggers/schedule/TriggerScheduleConfig.d.ts +1 -0
- package/dist/{client → client-v2}/triggers/schedule/constants.d.ts +8 -5
- package/dist/client-v2/triggers/schedule/index.d.ts +40 -0
- package/dist/client-v2/triggers/schedule/locale/Cron.zh-CN.d.ts +11 -0
- package/dist/common/executionStatus.d.ts +44 -0
- package/dist/common/executionStatus.js +133 -0
- package/dist/externalVersion.js +16 -12
- package/dist/locale/de-DE.json +14 -1
- package/dist/locale/en-US.json +21 -1
- package/dist/locale/es-ES.json +14 -1
- package/dist/locale/fr-FR.json +14 -1
- package/dist/locale/hu-HU.json +14 -1
- package/dist/locale/id-ID.json +14 -1
- package/dist/locale/it-IT.json +14 -1
- package/dist/locale/ja-JP.json +14 -1
- package/dist/locale/ko-KR.json +14 -1
- package/dist/locale/nl-NL.json +14 -1
- package/dist/locale/pt-BR.json +14 -1
- package/dist/locale/ru-RU.json +14 -1
- package/dist/locale/tr-TR.json +14 -1
- package/dist/locale/uk-UA.json +14 -1
- package/dist/locale/vi-VN.json +14 -1
- package/dist/locale/zh-CN.json +20 -1
- package/dist/locale/zh-TW.json +14 -1
- package/dist/node_modules/cron-parser/package.json +1 -1
- package/dist/node_modules/joi/package.json +1 -1
- package/dist/node_modules/lru-cache/package.json +1 -1
- package/dist/node_modules/nodejs-snowflake/package.json +1 -1
- package/dist/server/Processor.d.ts +16 -0
- package/dist/server/Processor.js +112 -0
- package/dist/server/index.d.ts +1 -1
- package/dist/server/instructions/CreateInstruction.js +6 -2
- package/dist/server/instructions/DestroyInstruction.js +2 -1
- package/dist/server/instructions/QueryInstruction.js +2 -1
- package/dist/server/instructions/UpdateInstruction.js +2 -1
- package/dist/server/triggers/CollectionTrigger.d.ts +5 -0
- package/dist/server/triggers/CollectionTrigger.js +26 -1
- package/package.json +3 -2
- package/dist/client/67.61e70b8b777f8638.js +0 -10
- package/dist/client/964.ffbf5b47ed12bbdc.js +0 -10
- package/dist/client/triggers/schedule/ScheduleModes.d.ts +0 -170
- package/dist/client/triggers/schedule/locale/Cron.zh-CN.d.ts +0 -42
|
@@ -6,9 +6,10 @@
|
|
|
6
6
|
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
7
|
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
8
|
*/
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
9
|
+
/**
|
|
10
|
+
* These pure utilities now live in `src/client-v2/canvas/nodeVariableUtils.ts`
|
|
11
|
+
* and are shared by both canvases (ADR-0003). This module re-exports them via
|
|
12
|
+
* the allowed `v1 → v2` import direction so existing v1 import sites are
|
|
13
|
+
* unchanged. Delete this file when the legacy canvas retires.
|
|
14
|
+
*/
|
|
15
|
+
export { extractDependencyKeys, stripVariableReferences, collectUpstreams, } from '../client-v2/canvas/nodeVariableUtils';
|
|
@@ -6,84 +6,12 @@
|
|
|
6
6
|
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
7
|
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
8
|
*/
|
|
9
|
-
import React from 'react';
|
|
10
9
|
import { SchemaInitializerItemType } from '@nocobase/client';
|
|
11
|
-
import {
|
|
12
|
-
import
|
|
13
|
-
|
|
14
|
-
import { SubModelItem } from '@nocobase/flow-engine';
|
|
15
|
-
export default class extends Instruction {
|
|
16
|
-
title: string;
|
|
17
|
-
type: string;
|
|
18
|
-
group: string;
|
|
19
|
-
description: string;
|
|
20
|
-
icon: React.JSX.Element;
|
|
21
|
-
fieldset: {
|
|
22
|
-
engine: {
|
|
23
|
-
type: string;
|
|
24
|
-
title: string;
|
|
25
|
-
'x-decorator': string;
|
|
26
|
-
'x-component': string;
|
|
27
|
-
'x-component-props': {
|
|
28
|
-
options: any;
|
|
29
|
-
};
|
|
30
|
-
required: boolean;
|
|
31
|
-
default: string;
|
|
32
|
-
};
|
|
33
|
-
expression: {
|
|
34
|
-
type: string;
|
|
35
|
-
title: string;
|
|
36
|
-
'x-decorator': string;
|
|
37
|
-
'x-component': string;
|
|
38
|
-
'x-component-props': {
|
|
39
|
-
changeOnSelect: boolean;
|
|
40
|
-
};
|
|
41
|
-
"x-validator"(value: any, rules: any, { form }: {
|
|
42
|
-
form: any;
|
|
43
|
-
}): string;
|
|
44
|
-
'x-reactions': {
|
|
45
|
-
dependencies: string[];
|
|
46
|
-
fulfill: {
|
|
47
|
-
schema: {
|
|
48
|
-
description: string;
|
|
49
|
-
};
|
|
50
|
-
};
|
|
51
|
-
}[];
|
|
52
|
-
required: boolean;
|
|
53
|
-
};
|
|
54
|
-
};
|
|
55
|
-
scope: {
|
|
56
|
-
renderEngineReference: (key: string) => React.JSX.Element;
|
|
57
|
-
};
|
|
58
|
-
components: {
|
|
59
|
-
WorkflowVariableTextArea: typeof WorkflowVariableTextArea;
|
|
60
|
-
RadioWithTooltip: typeof RadioWithTooltip;
|
|
61
|
-
ValueBlock: (() => JSX.Element) & {
|
|
62
|
-
Initializer: () => JSX.Element;
|
|
63
|
-
Result: (props: any) => JSX.Element;
|
|
64
|
-
Designer: () => JSX.Element;
|
|
65
|
-
};
|
|
66
|
-
};
|
|
67
|
-
useVariables({ key, title }: {
|
|
68
|
-
key: any;
|
|
69
|
-
title: any;
|
|
70
|
-
}, { types, fieldNames }: {
|
|
71
|
-
types: any;
|
|
72
|
-
fieldNames?: {
|
|
73
|
-
readonly label: "label";
|
|
74
|
-
readonly value: "value";
|
|
75
|
-
readonly children: "children";
|
|
76
|
-
};
|
|
77
|
-
}): {
|
|
78
|
-
value: any;
|
|
79
|
-
label: any;
|
|
80
|
-
};
|
|
10
|
+
import type { SubModelItem } from '@nocobase/flow-engine';
|
|
11
|
+
import V2CalculationInstruction from '../../client-v2/nodes/calculation';
|
|
12
|
+
export default class extends V2CalculationInstruction {
|
|
81
13
|
useInitializers(node: any): SchemaInitializerItemType;
|
|
82
|
-
/**
|
|
83
|
-
* 2.0
|
|
84
|
-
*/
|
|
85
14
|
getCreateModelMenuItem({ node }: {
|
|
86
15
|
node: any;
|
|
87
16
|
}): SubModelItem;
|
|
88
|
-
testable: boolean;
|
|
89
17
|
}
|
|
@@ -6,115 +6,11 @@
|
|
|
6
6
|
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
7
|
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
8
|
*/
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
type: string;
|
|
17
|
-
group: string;
|
|
18
|
-
description: string;
|
|
19
|
-
icon: React.JSX.Element;
|
|
20
|
-
fieldset: {
|
|
21
|
-
rejectOnFalse: {
|
|
22
|
-
type: string;
|
|
23
|
-
title: string;
|
|
24
|
-
'x-decorator': string;
|
|
25
|
-
'x-component': string;
|
|
26
|
-
'x-component-props': {
|
|
27
|
-
disabled: boolean;
|
|
28
|
-
};
|
|
29
|
-
enum: {
|
|
30
|
-
value: boolean;
|
|
31
|
-
label: string;
|
|
32
|
-
}[];
|
|
33
|
-
};
|
|
34
|
-
engine: {
|
|
35
|
-
type: string;
|
|
36
|
-
title: string;
|
|
37
|
-
'x-decorator': string;
|
|
38
|
-
'x-component': string;
|
|
39
|
-
'x-component-props': {
|
|
40
|
-
options: unknown;
|
|
41
|
-
};
|
|
42
|
-
required: boolean;
|
|
43
|
-
default: string;
|
|
44
|
-
};
|
|
45
|
-
calculation: {
|
|
46
|
-
type: string;
|
|
47
|
-
title: string;
|
|
48
|
-
'x-decorator': string;
|
|
49
|
-
'x-component': string;
|
|
50
|
-
'x-reactions': {
|
|
51
|
-
dependencies: string[];
|
|
52
|
-
fulfill: {
|
|
53
|
-
state: {
|
|
54
|
-
visible: string;
|
|
55
|
-
};
|
|
56
|
-
};
|
|
57
|
-
};
|
|
58
|
-
required: boolean;
|
|
59
|
-
};
|
|
60
|
-
expression: {
|
|
61
|
-
type: string;
|
|
62
|
-
title: string;
|
|
63
|
-
'x-decorator': string;
|
|
64
|
-
'x-component': string;
|
|
65
|
-
'x-component-props': {
|
|
66
|
-
changeOnSelect: boolean;
|
|
67
|
-
};
|
|
68
|
-
"x-validator"(value: any, rules: any, { form }: {
|
|
69
|
-
form: any;
|
|
70
|
-
}): string;
|
|
71
|
-
'x-reactions': {
|
|
72
|
-
dependencies: string[];
|
|
73
|
-
fulfill: {
|
|
74
|
-
state: {
|
|
75
|
-
visible: string;
|
|
76
|
-
};
|
|
77
|
-
schema: {
|
|
78
|
-
description: string;
|
|
79
|
-
};
|
|
80
|
-
};
|
|
81
|
-
};
|
|
82
|
-
required: boolean;
|
|
83
|
-
};
|
|
84
|
-
};
|
|
85
|
-
presetFieldset: {
|
|
86
|
-
rejectOnFalse: {
|
|
87
|
-
type: string;
|
|
88
|
-
title: string;
|
|
89
|
-
'x-decorator': string;
|
|
90
|
-
'x-component': string;
|
|
91
|
-
enum: {
|
|
92
|
-
label: string;
|
|
93
|
-
value: boolean;
|
|
94
|
-
}[];
|
|
95
|
-
default: boolean;
|
|
96
|
-
};
|
|
97
|
-
};
|
|
98
|
-
branching: ({ rejectOnFalse }?: {
|
|
99
|
-
rejectOnFalse?: boolean;
|
|
100
|
-
}) => false | ({
|
|
101
|
-
label: string;
|
|
102
|
-
value: 1;
|
|
103
|
-
} | {
|
|
104
|
-
label: string;
|
|
105
|
-
value: 0;
|
|
106
|
-
})[];
|
|
107
|
-
scope: {
|
|
108
|
-
renderEngineReference: (key: string) => React.JSX.Element;
|
|
109
|
-
useWorkflowVariableOptions: typeof useWorkflowVariableOptions;
|
|
110
|
-
};
|
|
111
|
-
components: {
|
|
112
|
-
CalculationConfig: typeof CalculationConfig;
|
|
113
|
-
WorkflowVariableTextArea: typeof WorkflowVariableTextArea;
|
|
114
|
-
RadioWithTooltip: typeof RadioWithTooltip;
|
|
115
|
-
};
|
|
116
|
-
Component({ data }: {
|
|
117
|
-
data: any;
|
|
118
|
-
}): React.JSX.Element;
|
|
119
|
-
testable: boolean;
|
|
9
|
+
/**
|
|
10
|
+
* v1 condition node. After sharing `Branch`, `AddNodeSlot`, and the branch-node
|
|
11
|
+
* renderer injection across runtimes, the legacy canvas can reuse the v2
|
|
12
|
+
* `ComponentLoader` directly. This file stays as a thin compatibility entry.
|
|
13
|
+
*/
|
|
14
|
+
import V2ConditionInstruction from '../../client-v2/nodes/condition';
|
|
15
|
+
export default class extends V2ConditionInstruction {
|
|
120
16
|
}
|
|
@@ -6,129 +6,8 @@
|
|
|
6
6
|
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
7
|
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
8
|
*/
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
|
|
12
|
-
import { Instruction, useNodeSavedConfig } from '.';
|
|
13
|
-
import { SubModelItem } from '@nocobase/flow-engine';
|
|
14
|
-
declare function useVariables({ key: name, title, config }: {
|
|
15
|
-
key: any;
|
|
16
|
-
title: any;
|
|
17
|
-
config: any;
|
|
18
|
-
}, options: any): import("../variable").VariableOption;
|
|
19
|
-
export default class extends Instruction {
|
|
20
|
-
title: string;
|
|
21
|
-
type: string;
|
|
22
|
-
group: string;
|
|
23
|
-
description: string;
|
|
24
|
-
icon: React.JSX.Element;
|
|
25
|
-
presetFieldset: {
|
|
26
|
-
collection: {
|
|
27
|
-
type: string;
|
|
28
|
-
title: string;
|
|
29
|
-
required: boolean;
|
|
30
|
-
'x-reactions': any[];
|
|
31
|
-
'x-decorator': string;
|
|
32
|
-
'x-component': string;
|
|
33
|
-
};
|
|
34
|
-
};
|
|
35
|
-
fieldset: {
|
|
36
|
-
collection: {
|
|
37
|
-
'x-disabled': string;
|
|
38
|
-
'x-reactions': any[];
|
|
39
|
-
type: string;
|
|
40
|
-
title: string;
|
|
41
|
-
required: boolean;
|
|
42
|
-
'x-decorator': string;
|
|
43
|
-
'x-component': string;
|
|
44
|
-
};
|
|
45
|
-
usingAssignFormSchema: {
|
|
46
|
-
type: string;
|
|
47
|
-
};
|
|
48
|
-
assignFormSchema: {
|
|
49
|
-
type: string;
|
|
50
|
-
title: string;
|
|
51
|
-
'x-decorator': string;
|
|
52
|
-
'x-component': string;
|
|
53
|
-
'x-reactions': {
|
|
54
|
-
dependencies: string[];
|
|
55
|
-
fulfill: {
|
|
56
|
-
state: {
|
|
57
|
-
display: string;
|
|
58
|
-
};
|
|
59
|
-
};
|
|
60
|
-
}[];
|
|
61
|
-
};
|
|
62
|
-
params: {
|
|
63
|
-
type: string;
|
|
64
|
-
properties: {
|
|
65
|
-
values: {
|
|
66
|
-
'x-reactions': {
|
|
67
|
-
dependencies: string[];
|
|
68
|
-
fulfill: {
|
|
69
|
-
state: {
|
|
70
|
-
display: string;
|
|
71
|
-
};
|
|
72
|
-
};
|
|
73
|
-
}[];
|
|
74
|
-
type: string;
|
|
75
|
-
title: string;
|
|
76
|
-
description: string;
|
|
77
|
-
'x-decorator': string;
|
|
78
|
-
'x-decorator-props': {
|
|
79
|
-
labelAlign: string;
|
|
80
|
-
className: string;
|
|
81
|
-
};
|
|
82
|
-
'x-component': string;
|
|
83
|
-
};
|
|
84
|
-
appends: {
|
|
85
|
-
type: string;
|
|
86
|
-
title: string;
|
|
87
|
-
description: string;
|
|
88
|
-
'x-decorator': string;
|
|
89
|
-
'x-component': string;
|
|
90
|
-
'x-component-props': {
|
|
91
|
-
title: string;
|
|
92
|
-
multiple: boolean;
|
|
93
|
-
useCollection(): any;
|
|
94
|
-
};
|
|
95
|
-
'x-reactions': {
|
|
96
|
-
dependencies: string[];
|
|
97
|
-
fulfill: {
|
|
98
|
-
state: {
|
|
99
|
-
visible: string;
|
|
100
|
-
};
|
|
101
|
-
};
|
|
102
|
-
}[];
|
|
103
|
-
};
|
|
104
|
-
};
|
|
105
|
-
};
|
|
106
|
-
};
|
|
107
|
-
createDefaultConfig(): {
|
|
108
|
-
usingAssignFormSchema: boolean;
|
|
109
|
-
assignFormSchema: {};
|
|
110
|
-
};
|
|
111
|
-
scope: {
|
|
112
|
-
useCollectionDataSource: typeof useCollectionDataSource;
|
|
113
|
-
useNodeSavedConfig: typeof useNodeSavedConfig;
|
|
114
|
-
};
|
|
115
|
-
components: {
|
|
116
|
-
CollectionFieldset: React.MemoExoticComponent<import("@formily/reactive-react").ReactFC<Omit<any, "ref">>>;
|
|
117
|
-
AssignedFieldsFormSchemaConfig: typeof AssignedFieldsFormSchemaConfig;
|
|
118
|
-
};
|
|
119
|
-
useVariables: typeof useVariables;
|
|
9
|
+
import { SchemaInitializerItemType } from '@nocobase/client';
|
|
10
|
+
import V2CreateInstruction from '../../client-v2/nodes/create';
|
|
11
|
+
export default class extends V2CreateInstruction {
|
|
120
12
|
useInitializers(node: any): SchemaInitializerItemType | null;
|
|
121
|
-
/**
|
|
122
|
-
* 2.0
|
|
123
|
-
*/
|
|
124
|
-
getCreateModelMenuItem({ node }: {
|
|
125
|
-
node: any;
|
|
126
|
-
}): SubModelItem;
|
|
127
|
-
useTempAssociationSource(node: any): {
|
|
128
|
-
collection: any;
|
|
129
|
-
nodeId: any;
|
|
130
|
-
nodeKey: any;
|
|
131
|
-
nodeType: "node";
|
|
132
|
-
};
|
|
133
13
|
}
|
|
134
|
-
export {};
|
|
@@ -6,61 +6,6 @@
|
|
|
6
6
|
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
7
|
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
8
|
*/
|
|
9
|
-
import
|
|
10
|
-
|
|
11
|
-
import { FilterDynamicComponent } from '../components/FilterDynamicComponent';
|
|
12
|
-
import { Instruction, useNodeSavedConfig } from '.';
|
|
13
|
-
export default class extends Instruction {
|
|
14
|
-
title: string;
|
|
15
|
-
type: string;
|
|
16
|
-
group: string;
|
|
17
|
-
description: string;
|
|
18
|
-
icon: React.JSX.Element;
|
|
19
|
-
presetFieldset: {
|
|
20
|
-
collection: {
|
|
21
|
-
type: string;
|
|
22
|
-
title: string;
|
|
23
|
-
required: boolean;
|
|
24
|
-
'x-reactions': any[];
|
|
25
|
-
'x-decorator': string;
|
|
26
|
-
'x-component': string;
|
|
27
|
-
};
|
|
28
|
-
};
|
|
29
|
-
fieldset: {
|
|
30
|
-
collection: {
|
|
31
|
-
'x-disabled': string;
|
|
32
|
-
'x-reactions': any[];
|
|
33
|
-
type: string;
|
|
34
|
-
title: string;
|
|
35
|
-
required: boolean;
|
|
36
|
-
'x-decorator': string;
|
|
37
|
-
'x-component': string;
|
|
38
|
-
};
|
|
39
|
-
params: {
|
|
40
|
-
type: string;
|
|
41
|
-
properties: {
|
|
42
|
-
filter: {
|
|
43
|
-
"x-validator"(value: any): string;
|
|
44
|
-
type: string;
|
|
45
|
-
title: string;
|
|
46
|
-
'x-decorator': string;
|
|
47
|
-
'x-component': string;
|
|
48
|
-
'x-use-component-props': () => {
|
|
49
|
-
options: any[];
|
|
50
|
-
className: string;
|
|
51
|
-
};
|
|
52
|
-
'x-component-props': {
|
|
53
|
-
dynamicComponent: string;
|
|
54
|
-
};
|
|
55
|
-
};
|
|
56
|
-
};
|
|
57
|
-
};
|
|
58
|
-
};
|
|
59
|
-
scope: {
|
|
60
|
-
useNodeSavedConfig: typeof useNodeSavedConfig;
|
|
61
|
-
useCollectionDataSource: typeof useCollectionDataSource;
|
|
62
|
-
};
|
|
63
|
-
components: {
|
|
64
|
-
FilterDynamicComponent: typeof FilterDynamicComponent;
|
|
65
|
-
};
|
|
9
|
+
import V2DestroyInstruction from '../../client-v2/nodes/destroy';
|
|
10
|
+
export default class extends V2DestroyInstruction {
|
|
66
11
|
}
|
|
@@ -6,27 +6,6 @@
|
|
|
6
6
|
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
7
|
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
8
|
*/
|
|
9
|
-
import
|
|
10
|
-
|
|
11
|
-
export default class extends Instruction {
|
|
12
|
-
title: string;
|
|
13
|
-
type: string;
|
|
14
|
-
group: string;
|
|
15
|
-
description: string;
|
|
16
|
-
icon: React.JSX.Element;
|
|
17
|
-
fieldset: {
|
|
18
|
-
endStatus: {
|
|
19
|
-
type: string;
|
|
20
|
-
title: string;
|
|
21
|
-
'x-decorator': string;
|
|
22
|
-
'x-component': string;
|
|
23
|
-
enum: {
|
|
24
|
-
label: string;
|
|
25
|
-
value: number;
|
|
26
|
-
}[];
|
|
27
|
-
required: boolean;
|
|
28
|
-
default: number;
|
|
29
|
-
};
|
|
30
|
-
};
|
|
31
|
-
end: boolean;
|
|
9
|
+
import V2EndInstruction from '../../client-v2/nodes/end';
|
|
10
|
+
export default class extends V2EndInstruction {
|
|
32
11
|
}
|
|
@@ -6,104 +6,16 @@
|
|
|
6
6
|
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
7
|
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
8
|
*/
|
|
9
|
-
import { ISchema } from '@formily/react';
|
|
10
9
|
import React from 'react';
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
import { UseVariableOptions, VariableOption } from '../variable';
|
|
14
|
-
import { SubModelItem } from '@nocobase/flow-engine';
|
|
15
|
-
export type NodeAvailableContext = {
|
|
16
|
-
engine: WorkflowPlugin;
|
|
17
|
-
workflow: object;
|
|
18
|
-
upstream: object;
|
|
19
|
-
branchIndex: number;
|
|
20
|
-
syncOnly?: boolean;
|
|
21
|
-
};
|
|
22
|
-
type Config = Record<string, any>;
|
|
23
|
-
type Options = {
|
|
24
|
-
label: string;
|
|
25
|
-
value: any;
|
|
26
|
-
}[];
|
|
27
|
-
export declare abstract class Instruction {
|
|
28
|
-
title: string;
|
|
29
|
-
type: string;
|
|
30
|
-
group: string;
|
|
31
|
-
description?: string;
|
|
32
|
-
icon?: JSX.Element;
|
|
33
|
-
async?: boolean;
|
|
34
|
-
/**
|
|
35
|
-
* @deprecated migrate to `presetFieldset` instead
|
|
36
|
-
*/
|
|
37
|
-
options?: {
|
|
38
|
-
label: string;
|
|
39
|
-
value: any;
|
|
40
|
-
key: string;
|
|
41
|
-
}[];
|
|
42
|
-
fieldset: Record<string, ISchema>;
|
|
43
|
-
/**
|
|
44
|
-
* @experimental
|
|
45
|
-
*/
|
|
46
|
-
presetFieldset?: Record<string, ISchema>;
|
|
47
|
-
/**
|
|
48
|
-
* To presentation if the instruction is creating a branch
|
|
49
|
-
* @experimental
|
|
50
|
-
*/
|
|
51
|
-
branching?: boolean | Options | ((config: Config) => boolean | Options);
|
|
52
|
-
/**
|
|
53
|
-
* @experimental
|
|
54
|
-
*/
|
|
55
|
-
view?: ISchema;
|
|
56
|
-
scope?: Record<string, any>;
|
|
57
|
-
components?: Record<string, any>;
|
|
58
|
-
Component?(props: any): JSX.Element;
|
|
59
|
-
/**
|
|
60
|
-
* @experimental
|
|
61
|
-
*/
|
|
62
|
-
createDefaultConfig?(): Config;
|
|
63
|
-
useVariables?(node: any, options?: UseVariableOptions): VariableOption;
|
|
64
|
-
useScopeVariables?(node: any, options?: any): VariableOption[];
|
|
65
|
-
useInitializers?(node: any): SchemaInitializerItemType | null;
|
|
66
|
-
/**
|
|
67
|
-
* @experimental
|
|
68
|
-
*/
|
|
69
|
-
isAvailable?(ctx: NodeAvailableContext): boolean;
|
|
70
|
-
end?: boolean | ((node: any) => boolean);
|
|
71
|
-
testable?: boolean;
|
|
72
|
-
/**
|
|
73
|
-
* 2.0
|
|
74
|
-
*/
|
|
75
|
-
getCreateModelMenuItem?({ node, workflow }: {
|
|
76
|
-
node: any;
|
|
77
|
-
workflow: any;
|
|
78
|
-
}): SubModelItem | null;
|
|
79
|
-
/**
|
|
80
|
-
* @experimental
|
|
81
|
-
*/
|
|
82
|
-
useTempAssociationSource?(node: any): TempAssociationSource | null;
|
|
83
|
-
}
|
|
84
|
-
export type TempAssociationSource = {
|
|
85
|
-
collection: string;
|
|
86
|
-
nodeId: string | number;
|
|
87
|
-
nodeKey: string;
|
|
88
|
-
nodeType: 'workflow' | 'node';
|
|
89
|
-
};
|
|
10
|
+
export { Instruction, NodeContext, useNodeContext, useAvailableUpstreams, useUpstreamScopes, } from '../../client-v2/canvas/Instruction';
|
|
11
|
+
export type { NodeAvailableContext, TempAssociationSource } from '../../client-v2/canvas/Instruction';
|
|
90
12
|
export declare function updateNodeConfig({ api, nodeId, config, resourceName }: {
|
|
91
13
|
api: any;
|
|
92
14
|
nodeId: any;
|
|
93
15
|
config: any;
|
|
94
16
|
resourceName?: string;
|
|
95
17
|
}): Promise<void>;
|
|
96
|
-
export declare const NodeContext: React.Context<any>;
|
|
97
|
-
export declare function useNodeContext(): any;
|
|
98
18
|
export declare function useNodeSavedConfig(keys?: any[]): boolean;
|
|
99
|
-
/**
|
|
100
|
-
* @experimental
|
|
101
|
-
*/
|
|
102
|
-
export declare function useAvailableUpstreams(node: any, filter?: any): any[];
|
|
103
|
-
/**
|
|
104
|
-
* @experimental
|
|
105
|
-
*/
|
|
106
|
-
export declare function useUpstreamScopes(node: any): any[];
|
|
107
19
|
export declare function Node({ data }: {
|
|
108
20
|
data: any;
|
|
109
21
|
}): React.JSX.Element;
|
|
@@ -113,4 +25,3 @@ export declare function LogCollapse({ value }: {
|
|
|
113
25
|
value: any;
|
|
114
26
|
}): React.JSX.Element;
|
|
115
27
|
export declare function NodeDefaultView(props: any): React.JSX.Element;
|
|
116
|
-
export {};
|
|
@@ -6,52 +6,14 @@
|
|
|
6
6
|
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
7
|
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
8
|
*/
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
group: string;
|
|
20
|
-
description: string;
|
|
21
|
-
icon: React.JSX.Element;
|
|
22
|
-
fieldset: {
|
|
23
|
-
continueOnNoMatch: {
|
|
24
|
-
type: string;
|
|
25
|
-
title: string;
|
|
26
|
-
'x-decorator': string;
|
|
27
|
-
'x-component': string;
|
|
28
|
-
'x-component-props': {
|
|
29
|
-
options: {
|
|
30
|
-
label: string;
|
|
31
|
-
value: boolean;
|
|
32
|
-
}[];
|
|
33
|
-
};
|
|
34
|
-
default: boolean;
|
|
35
|
-
};
|
|
36
|
-
};
|
|
37
|
-
branching: {
|
|
38
|
-
label: string;
|
|
39
|
-
value: number;
|
|
40
|
-
}[];
|
|
41
|
-
scope: {
|
|
42
|
-
renderEngineReference: (key: string) => React.JSX.Element;
|
|
43
|
-
useWorkflowVariableOptions: typeof useWorkflowVariableOptions;
|
|
44
|
-
};
|
|
45
|
-
components: {
|
|
46
|
-
WorkflowVariableTextArea: typeof WorkflowVariableTextArea;
|
|
47
|
-
RadioWithTooltip: typeof RadioWithTooltip;
|
|
48
|
-
};
|
|
49
|
-
Component: typeof NodeComponent;
|
|
50
|
-
createDefaultConfig(): {
|
|
51
|
-
conditions: {
|
|
52
|
-
uid: any;
|
|
53
|
-
}[];
|
|
54
|
-
continueOnNoMatch: boolean;
|
|
55
|
-
};
|
|
9
|
+
/**
|
|
10
|
+
* v1 multi-conditions node. After sharing `Branch`, `AddNodeSlot`, recursive
|
|
11
|
+
* branch-node rendering, and the add-node controller across runtimes, the
|
|
12
|
+
* legacy canvas can reuse the v2 branch render directly. Branch condition
|
|
13
|
+
* configuration is allowed to keep using the v2 dialog; only add-node drawers
|
|
14
|
+
* remain runtime-specific and are already routed through the shared add-node
|
|
15
|
+
* context chain.
|
|
16
|
+
*/
|
|
17
|
+
import V2MultiConditionsInstruction from '../../client-v2/nodes/multi-conditions';
|
|
18
|
+
export default class extends V2MultiConditionsInstruction {
|
|
56
19
|
}
|
|
57
|
-
export {};
|
|
@@ -6,48 +6,6 @@
|
|
|
6
6
|
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
7
|
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
8
|
*/
|
|
9
|
-
import
|
|
10
|
-
|
|
11
|
-
import { WorkflowVariableInput } from '../variable';
|
|
12
|
-
export default class extends Instruction {
|
|
13
|
-
title: string;
|
|
14
|
-
type: string;
|
|
15
|
-
group: string;
|
|
16
|
-
description: string;
|
|
17
|
-
icon: React.JSX.Element;
|
|
18
|
-
fieldset: {
|
|
19
|
-
value: {
|
|
20
|
-
type: string;
|
|
21
|
-
'x-decorator': string;
|
|
22
|
-
'x-component': string;
|
|
23
|
-
'x-component-props': {
|
|
24
|
-
changeOnSelect: boolean;
|
|
25
|
-
useTypedConstant: boolean;
|
|
26
|
-
nullable: boolean;
|
|
27
|
-
autoSize: {
|
|
28
|
-
minRows: number;
|
|
29
|
-
};
|
|
30
|
-
placeholder: string;
|
|
31
|
-
};
|
|
32
|
-
title: string;
|
|
33
|
-
};
|
|
34
|
-
};
|
|
35
|
-
scope: {};
|
|
36
|
-
components: {
|
|
37
|
-
ArrayItems: import("@formily/reactive-react").ReactFC<React.HTMLAttributes<HTMLDivElement>> & import("@formily/antd-v5").ArrayBaseMixins & {
|
|
38
|
-
Item: import("@formily/reactive-react").ReactFC<React.HTMLAttributes<HTMLDivElement> & {
|
|
39
|
-
type?: "divide" | "card";
|
|
40
|
-
}>;
|
|
41
|
-
};
|
|
42
|
-
WorkflowVariableInput: typeof WorkflowVariableInput;
|
|
43
|
-
};
|
|
44
|
-
useVariables({ key, title }: {
|
|
45
|
-
key: any;
|
|
46
|
-
title: any;
|
|
47
|
-
}, { types }: {
|
|
48
|
-
types: any;
|
|
49
|
-
}): {
|
|
50
|
-
value: any;
|
|
51
|
-
label: any;
|
|
52
|
-
};
|
|
9
|
+
import V2OutputInstruction from '../../client-v2/nodes/output';
|
|
10
|
+
export default class extends V2OutputInstruction {
|
|
53
11
|
}
|