@nocobase/plugin-workflow 2.0.0-alpha.6 → 2.0.0-alpha.60

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.
Files changed (58) hide show
  1. package/dist/client/{f68fbc145c3ddec3.js → 80d4cd8911e03c27.js} +1 -1
  2. package/dist/client/Branch.d.ts +2 -0
  3. package/dist/client/RemoveNodeContext.d.ts +11 -0
  4. package/dist/client/WorkflowTasks.d.ts +3 -1
  5. package/dist/client/bfc2a351589613e1.js +10 -0
  6. package/dist/client/e078314a62391f36.js +10 -0
  7. package/dist/client/flows/triggerWorkflows.d.ts +15 -42
  8. package/dist/client/index.js +1 -1
  9. package/dist/client/nodes/condition.d.ts +0 -3
  10. package/dist/client/nodes/multi-conditions.d.ts +57 -0
  11. package/dist/client/schemas/executions.d.ts +1 -1
  12. package/dist/client/variable.d.ts +1 -1
  13. package/dist/common/collections/executions.d.ts +1 -1
  14. package/dist/common/collections/executions.js +13 -1
  15. package/dist/common/collections/jobs.js +4 -0
  16. package/dist/externalVersion.js +12 -11
  17. package/dist/locale/de-DE.json +230 -188
  18. package/dist/locale/en-US.json +233 -188
  19. package/dist/locale/es-ES.json +238 -78
  20. package/dist/locale/fr-FR.json +238 -78
  21. package/dist/locale/hu-HU.json +258 -0
  22. package/dist/locale/id-ID.json +258 -0
  23. package/dist/locale/it-IT.json +229 -176
  24. package/dist/locale/ja-JP.json +236 -164
  25. package/dist/locale/ko-KR.json +260 -150
  26. package/dist/locale/nl-NL.json +257 -99
  27. package/dist/locale/pt-BR.json +238 -78
  28. package/dist/locale/ru-RU.json +243 -67
  29. package/dist/locale/tr-TR.json +239 -63
  30. package/dist/locale/uk-UA.json +258 -0
  31. package/dist/locale/vi-VN.json +258 -0
  32. package/dist/locale/zh-CN.json +236 -226
  33. package/dist/locale/zh-TW.json +258 -0
  34. package/dist/node_modules/cron-parser/package.json +1 -1
  35. package/dist/node_modules/lru-cache/package.json +1 -1
  36. package/dist/node_modules/nodejs-snowflake/package.json +1 -1
  37. package/dist/server/Dispatcher.d.ts +1 -3
  38. package/dist/server/Dispatcher.js +30 -30
  39. package/dist/server/Plugin.d.ts +3 -0
  40. package/dist/server/Plugin.js +55 -20
  41. package/dist/server/Processor.js +37 -12
  42. package/dist/server/actions/index.js +3 -0
  43. package/dist/server/actions/jobs.d.ts +9 -0
  44. package/dist/server/actions/jobs.js +64 -0
  45. package/dist/server/actions/nodes.d.ts +1 -0
  46. package/dist/server/actions/nodes.js +148 -17
  47. package/dist/server/instructions/MultiConditionsInstruction.d.ts +18 -0
  48. package/dist/server/instructions/MultiConditionsInstruction.js +118 -0
  49. package/dist/server/instructions/index.d.ts +3 -1
  50. package/dist/server/repositories/WorkflowRepository.js +9 -2
  51. package/dist/server/triggers/CollectionTrigger.d.ts +3 -0
  52. package/dist/server/triggers/CollectionTrigger.js +31 -3
  53. package/dist/server/triggers/ScheduleTrigger/DateFieldScheduleTrigger.js +8 -0
  54. package/dist/server/triggers/index.d.ts +3 -1
  55. package/dist/server/types/Job.d.ts +1 -0
  56. package/package.json +5 -2
  57. package/dist/client/4985975bcaea35eb.js +0 -10
  58. package/dist/client/91bf4b18d5aad6a7.js +0 -10
@@ -98,9 +98,6 @@ export default class extends Instruction {
98
98
  branching: ({ rejectOnFalse }?: {
99
99
  rejectOnFalse?: boolean;
100
100
  }) => false | ({
101
- label: string;
102
- value: boolean;
103
- } | {
104
101
  label: string;
105
102
  value: 1;
106
103
  } | {
@@ -0,0 +1,57 @@
1
+ /**
2
+ * This file is part of the NocoBase (R) project.
3
+ * Copyright (c) 2020-2024 NocoBase Co., Ltd.
4
+ * Authors: NocoBase Team.
5
+ *
6
+ * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
7
+ * For more information, please refer to: https://www.nocobase.com/agreement.
8
+ */
9
+ import React from 'react';
10
+ import { Instruction } from '.';
11
+ import { RadioWithTooltip } from '../components/RadioWithTooltip';
12
+ import { useWorkflowVariableOptions, WorkflowVariableTextArea } from '../variable';
13
+ declare function NodeComponent({ data }: {
14
+ data: any;
15
+ }): React.JSX.Element;
16
+ export default class extends Instruction {
17
+ title: string;
18
+ type: string;
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
+ };
56
+ }
57
+ export {};
@@ -140,9 +140,9 @@ export declare const executionSchema: {
140
140
  unique?: undefined;
141
141
  onDelete?: undefined;
142
142
  } | {
143
- interface: string;
144
143
  type: string;
145
144
  name: string;
145
+ interface: string;
146
146
  uiSchema: {
147
147
  type: string;
148
148
  title: string;
@@ -11,7 +11,7 @@ import { CollectionManager } from '@nocobase/client';
11
11
  export type VariableOption = {
12
12
  key?: string;
13
13
  value?: string;
14
- label?: string;
14
+ label?: string | React.ReactNode;
15
15
  children?: VariableOption[] | null;
16
16
  [key: string]: any;
17
17
  };
@@ -129,9 +129,9 @@ declare const _default: {
129
129
  unique?: undefined;
130
130
  onDelete?: undefined;
131
131
  } | {
132
- interface: string;
133
132
  type: string;
134
133
  name: string;
134
+ interface: string;
135
135
  uiSchema: {
136
136
  type: string;
137
137
  title: string;
@@ -115,9 +115,9 @@ var executions_default = {
115
115
  name: "output"
116
116
  },
117
117
  {
118
- interface: "createdAt",
119
118
  type: "datetime",
120
119
  name: "createdAt",
120
+ interface: "createdAt",
121
121
  uiSchema: {
122
122
  type: "datetime",
123
123
  title: `{{t("Triggered at", { ns: "${import_constants.NAMESPACE}" })}}`,
@@ -125,6 +125,18 @@ var executions_default = {
125
125
  "x-component-props": {},
126
126
  "x-read-pretty": true
127
127
  }
128
+ },
129
+ {
130
+ type: "boolean",
131
+ name: "manually",
132
+ interface: "checkbox",
133
+ uiSchema: {
134
+ type: "boolean",
135
+ title: `{{t("Triggered manually", { ns: "${import_constants.NAMESPACE}" })}}`,
136
+ "x-component": "Checkbox",
137
+ "x-component-props": {},
138
+ "x-read-pretty": true
139
+ }
128
140
  }
129
141
  ],
130
142
  indexes: [{ fields: ["dispatched", "id"] }]
@@ -66,6 +66,10 @@ var jobs_default = {
66
66
  type: "integer",
67
67
  name: "status"
68
68
  },
69
+ {
70
+ type: "json",
71
+ name: "meta"
72
+ },
69
73
  {
70
74
  type: "json",
71
75
  name: "result"
@@ -11,8 +11,8 @@ module.exports = {
11
11
  "react": "18.2.0",
12
12
  "@formily/core": "2.3.7",
13
13
  "@formily/react": "2.3.7",
14
- "@nocobase/client": "2.0.0-alpha.6",
15
- "@nocobase/utils": "2.0.0-alpha.6",
14
+ "@nocobase/client": "2.0.0-alpha.60",
15
+ "@nocobase/utils": "2.0.0-alpha.60",
16
16
  "antd": "5.24.2",
17
17
  "@ant-design/icons": "5.6.1",
18
18
  "react-router-dom": "6.30.1",
@@ -20,17 +20,18 @@ module.exports = {
20
20
  "lodash": "4.17.21",
21
21
  "@dnd-kit/core": "6.1.0",
22
22
  "@formily/shared": "2.3.7",
23
- "@nocobase/plugin-mobile": "2.0.0-alpha.6",
23
+ "@nocobase/flow-engine": "2.0.0-alpha.60",
24
+ "@nocobase/plugin-mobile": "2.0.0-alpha.60",
24
25
  "sequelize": "6.35.2",
25
- "@nocobase/database": "2.0.0-alpha.6",
26
- "@nocobase/server": "2.0.0-alpha.6",
27
- "@nocobase/data-source-manager": "2.0.0-alpha.6",
28
- "@nocobase/logger": "2.0.0-alpha.6",
29
- "@nocobase/evaluators": "2.0.0-alpha.6",
26
+ "@nocobase/server": "2.0.0-alpha.60",
27
+ "@nocobase/database": "2.0.0-alpha.60",
28
+ "@nocobase/data-source-manager": "2.0.0-alpha.60",
29
+ "@nocobase/logger": "2.0.0-alpha.60",
30
+ "@nocobase/evaluators": "2.0.0-alpha.60",
30
31
  "@formily/antd-v5": "1.2.3",
31
32
  "@formily/reactive": "2.3.7",
32
- "@nocobase/actions": "2.0.0-alpha.6",
33
+ "@nocobase/actions": "2.0.0-alpha.60",
33
34
  "dayjs": "1.11.13",
34
- "@nocobase/plugin-workflow-test": "2.0.0-alpha.6",
35
- "@nocobase/test": "2.0.0-alpha.6"
35
+ "@nocobase/plugin-workflow-test": "2.0.0-alpha.60",
36
+ "@nocobase/test": "2.0.0-alpha.60"
36
37
  };