@nocobase/plugin-workflow 1.2.1-alpha → 1.2.2-alpha

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.
@@ -8,7 +8,8 @@
8
8
  */
9
9
  /// <reference types="react" />
10
10
  import { SchemaInitializerItemType, useCollectionDataSource } from '@nocobase/client';
11
- import { Instruction } from '.';
11
+ import { AssignedFieldsFormSchemaConfig } from '../components/AssignedFieldsFormSchemaConfig';
12
+ import { Instruction, useNodeSavedConfig } from '.';
12
13
  declare function useVariables({ key: name, title, config }: {
13
14
  key: any;
14
15
  title: any;
@@ -21,6 +22,7 @@ export default class extends Instruction {
21
22
  description: string;
22
23
  fieldset: {
23
24
  collection: {
25
+ 'x-disabled': string;
24
26
  'x-reactions': any[];
25
27
  type: string;
26
28
  title: string;
@@ -28,10 +30,32 @@ export default class extends Instruction {
28
30
  'x-decorator': string;
29
31
  'x-component': string;
30
32
  };
33
+ assignFormSchema: {
34
+ type: string;
35
+ title: string;
36
+ 'x-decorator': string;
37
+ 'x-component': string;
38
+ 'x-reactions': {
39
+ dependencies: string[];
40
+ fulfill: {
41
+ state: {
42
+ display: string;
43
+ };
44
+ };
45
+ }[];
46
+ };
31
47
  params: {
32
48
  type: string;
33
49
  properties: {
34
50
  values: {
51
+ 'x-reactions': {
52
+ dependencies: string[];
53
+ fulfill: {
54
+ state: {
55
+ display: string;
56
+ };
57
+ };
58
+ }[];
35
59
  type: string;
36
60
  title: string;
37
61
  description: string;
@@ -65,11 +89,16 @@ export default class extends Instruction {
65
89
  };
66
90
  };
67
91
  };
92
+ createDefaultConfig(): {
93
+ assignFormSchema: {};
94
+ };
68
95
  scope: {
69
96
  useCollectionDataSource: typeof useCollectionDataSource;
97
+ useNodeSavedConfig: typeof useNodeSavedConfig;
70
98
  };
71
99
  components: {
72
100
  CollectionFieldset: import("react").MemoExoticComponent<import("@formily/reactive-react").ReactFC<Omit<any, "ref">>>;
101
+ AssignedFieldsFormSchemaConfig: typeof AssignedFieldsFormSchemaConfig;
73
102
  };
74
103
  useVariables: typeof useVariables;
75
104
  useInitializers(node: any): SchemaInitializerItemType | null;
@@ -8,7 +8,7 @@
8
8
  */
9
9
  import { useCollectionDataSource } from '@nocobase/client';
10
10
  import { FilterDynamicComponent } from '../components/FilterDynamicComponent';
11
- import { Instruction } from '.';
11
+ import { Instruction, useNodeSavedConfig } from '.';
12
12
  export default class extends Instruction {
13
13
  title: string;
14
14
  type: string;
@@ -16,6 +16,7 @@ export default class extends Instruction {
16
16
  description: string;
17
17
  fieldset: {
18
18
  collection: {
19
+ 'x-disabled': string;
19
20
  'x-reactions': any[];
20
21
  type: string;
21
22
  title: string;
@@ -44,6 +45,7 @@ export default class extends Instruction {
44
45
  };
45
46
  };
46
47
  scope: {
48
+ useNodeSavedConfig: typeof useNodeSavedConfig;
47
49
  useCollectionDataSource: typeof useCollectionDataSource;
48
50
  };
49
51
  components: {
@@ -22,6 +22,9 @@ export declare abstract class Instruction {
22
22
  type: string;
23
23
  group: string;
24
24
  description?: string;
25
+ /**
26
+ * @experimental
27
+ */
25
28
  options?: {
26
29
  label: string;
27
30
  value: any;
@@ -30,6 +33,9 @@ export declare abstract class Instruction {
30
33
  fieldset: {
31
34
  [key: string]: ISchema;
32
35
  };
36
+ /**
37
+ * @experimental
38
+ */
33
39
  view?: ISchema;
34
40
  scope?: {
35
41
  [key: string]: any;
@@ -38,14 +44,22 @@ export declare abstract class Instruction {
38
44
  [key: string]: any;
39
45
  };
40
46
  Component?(props: any): JSX.Element;
47
+ /**
48
+ * @experimental
49
+ */
50
+ createDefaultConfig?(): Record<string, any>;
41
51
  useVariables?(node: any, options?: UseVariableOptions): VariableOption;
42
52
  useScopeVariables?(node: any, options?: any): VariableOption[];
43
53
  useInitializers?(node: any): SchemaInitializerItemType | null;
54
+ /**
55
+ * @experimental
56
+ */
44
57
  isAvailable?(ctx: NodeAvailableContext): boolean;
45
58
  end?: boolean | ((node: any) => boolean);
46
59
  }
47
60
  export declare const NodeContext: React.Context<any>;
48
61
  export declare function useNodeContext(): any;
62
+ export declare function useNodeSavedConfig(keys?: any[]): boolean;
49
63
  /**
50
64
  * @experimental
51
65
  */
@@ -10,7 +10,7 @@
10
10
  import { SchemaInitializerItemType, useCollectionDataSource } from '@nocobase/client';
11
11
  import { FilterDynamicComponent } from '../components/FilterDynamicComponent';
12
12
  import { WorkflowVariableInput } from '../variable';
13
- import { Instruction } from '.';
13
+ import { Instruction, useNodeSavedConfig } from '.';
14
14
  import { RadioWithTooltip } from '../components';
15
15
  declare function useVariables({ key: name, title, config }: {
16
16
  key: any;
@@ -24,6 +24,7 @@ export default class extends Instruction {
24
24
  description: string;
25
25
  fieldset: {
26
26
  collection: {
27
+ 'x-disabled': string;
27
28
  'x-reactions': any[];
28
29
  type: string;
29
30
  title: string;
@@ -211,6 +212,7 @@ export default class extends Instruction {
211
212
  };
212
213
  };
213
214
  scope: {
215
+ useNodeSavedConfig: typeof useNodeSavedConfig;
214
216
  useCollectionDataSource: typeof useCollectionDataSource;
215
217
  useSortableFields(): {
216
218
  value: any;
@@ -6,14 +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';
9
+ /// <reference types="react" />
10
10
  import { useCollectionDataSource } from '@nocobase/client';
11
+ import { AssignedFieldsFormSchemaConfig } from '../components/AssignedFieldsFormSchemaConfig';
11
12
  import { FilterDynamicComponent } from '../components/FilterDynamicComponent';
12
- import { Instruction } from '.';
13
- declare function IndividualHooksRadioWithTooltip({ onChange, ...props }: {
14
- [x: string]: any;
15
- onChange: any;
16
- }): React.JSX.Element;
13
+ import { RadioWithTooltip } from '../components/RadioWithTooltip';
14
+ import { Instruction, useNodeSavedConfig } from '.';
17
15
  export default class extends Instruction {
18
16
  title: string;
19
17
  type: string;
@@ -21,6 +19,7 @@ export default class extends Instruction {
21
19
  description: string;
22
20
  fieldset: {
23
21
  collection: {
22
+ 'x-disabled': string;
24
23
  'x-reactions': any[];
25
24
  type: string;
26
25
  title: string;
@@ -60,9 +59,14 @@ export default class extends Instruction {
60
59
  };
61
60
  };
62
61
  values: {
63
- 'x-component-props': {
64
- filter(this: any, field: any): any;
65
- };
62
+ 'x-reactions': {
63
+ dependencies: string[];
64
+ fulfill: {
65
+ state: {
66
+ display: string;
67
+ };
68
+ };
69
+ }[];
66
70
  type: string;
67
71
  title: string;
68
72
  description: string;
@@ -75,14 +79,32 @@ export default class extends Instruction {
75
79
  };
76
80
  };
77
81
  };
82
+ assignFormSchema: {
83
+ type: string;
84
+ title: string;
85
+ 'x-decorator': string;
86
+ 'x-component': string;
87
+ 'x-reactions': {
88
+ dependencies: string[];
89
+ fulfill: {
90
+ state: {
91
+ display: string;
92
+ };
93
+ };
94
+ }[];
95
+ };
96
+ };
97
+ createDefaultConfig(): {
98
+ assignForm: string;
78
99
  };
79
100
  scope: {
80
101
  useCollectionDataSource: typeof useCollectionDataSource;
102
+ useNodeSavedConfig: typeof useNodeSavedConfig;
81
103
  };
82
104
  components: {
83
105
  FilterDynamicComponent: typeof FilterDynamicComponent;
84
- CollectionFieldset: React.MemoExoticComponent<import("@formily/react").ReactFC<Omit<any, "ref">>>;
85
- IndividualHooksRadioWithTooltip: typeof IndividualHooksRadioWithTooltip;
106
+ CollectionFieldset: import("react").MemoExoticComponent<import("@formily/reactive-react").ReactFC<Omit<any, "ref">>>;
107
+ AssignedFieldsFormSchemaConfig: typeof AssignedFieldsFormSchemaConfig;
108
+ RadioWithTooltip: typeof RadioWithTooltip;
86
109
  };
87
110
  }
88
- export {};
@@ -11,23 +11,24 @@ module.exports = {
11
11
  "react": "18.2.0",
12
12
  "antd": "5.12.8",
13
13
  "@ant-design/icons": "5.2.6",
14
- "@nocobase/client": "1.2.1-alpha",
14
+ "@nocobase/client": "1.2.2-alpha",
15
15
  "react-router-dom": "6.21.0",
16
- "@nocobase/utils": "1.2.1-alpha",
16
+ "@nocobase/utils": "1.2.2-alpha",
17
17
  "react-i18next": "11.18.6",
18
18
  "@formily/core": "2.3.0",
19
19
  "@formily/react": "2.3.0",
20
20
  "lodash": "4.17.21",
21
- "@nocobase/database": "1.2.1-alpha",
22
- "@nocobase/server": "1.2.1-alpha",
23
- "@nocobase/logger": "1.2.1-alpha",
24
- "@nocobase/evaluators": "1.2.1-alpha",
25
- "@formily/shared": "2.3.0",
21
+ "@nocobase/database": "1.2.2-alpha",
22
+ "@nocobase/server": "1.2.2-alpha",
23
+ "@nocobase/logger": "1.2.2-alpha",
24
+ "@nocobase/evaluators": "1.2.2-alpha",
26
25
  "@formily/antd-v5": "1.1.9",
27
- "@nocobase/actions": "1.2.1-alpha",
28
- "@nocobase/data-source-manager": "1.2.1-alpha",
26
+ "@formily/reactive": "2.3.0",
27
+ "@formily/shared": "2.3.0",
28
+ "@nocobase/actions": "1.2.2-alpha",
29
+ "@nocobase/data-source-manager": "1.2.2-alpha",
29
30
  "sequelize": "6.35.2",
30
- "@nocobase/plugin-workflow-test": "1.2.1-alpha",
31
- "@nocobase/test": "1.2.1-alpha",
31
+ "@nocobase/plugin-workflow-test": "1.2.2-alpha",
32
+ "@nocobase/test": "1.2.2-alpha",
32
33
  "dayjs": "1.11.10"
33
34
  };
@@ -1 +1 @@
1
- {"name":"cron-parser","version":"4.4.0","description":"Node.js library for parsing crontab instructions","main":"lib/parser.js","types":"index.d.ts","typesVersions":{"<4.1":{"*":["types/ts3/*"]}},"directories":{"test":"test"},"scripts":{"test:tsd":"tsd","test:unit":"TZ=UTC tap ./test/*.js","test:cover":"TZ=UTC tap --coverage-report=html ./test/*.js","lint":"eslint .","lint:fix":"eslint --fix .","test":"npm run lint && npm run test:unit && npm run test:tsd"},"repository":{"type":"git","url":"https://github.com/harrisiirak/cron-parser.git"},"keywords":["cron","crontab","parser"],"author":"Harri Siirak","contributors":["Nicholas Clawson","Daniel Prentis <daniel@salsitasoft.com>","Renault John Lecoultre","Richard Astbury <richard.astbury@gmail.com>","Meaglin Wasabi <Meaglin.wasabi@gmail.com>","Mike Kusold <hello@mikekusold.com>","Alex Kit <alex.kit@atmajs.com>","Santiago Gimeno <santiago.gimeno@gmail.com>","Daniel <darc.tec@gmail.com>","Christian Steininger <christian.steininger.cs@gmail.com>","Mykola Piskovyi <m.piskovyi@gmail.com>","Brian Vaughn <brian.david.vaughn@gmail.com>","Nicholas Clawson <nickclaw@gmail.com>","Yasuhiroki <yasuhiroki.duck@gmail.com>","Nicholas Clawson <nickclaw@gmail.com>","Brendan Warkentin <faazshift@gmail.com>","Charlie Fish <fishcharlie.code@gmail.com>","Ian Graves <ian+diskimage@iangrav.es>","Andy Thompson <me@andytson.com>","Regev Brody <regevbr@gmail.com>"],"license":"MIT","dependencies":{"luxon":"^1.28.0"},"devDependencies":{"eslint":"^8.2.0","sinon":"^10.0.0","tap":"^16.0.1","tsd":"^0.19.0"},"engines":{"node":">=0.8"},"browser":{"fs":false},"tap":{"check-coverage":false},"tsd":{"directory":"test","compilerOptions":{"lib":["es2017","dom"]}},"_lastModified":"2024-06-12T05:27:08.521Z"}
1
+ {"name":"cron-parser","version":"4.4.0","description":"Node.js library for parsing crontab instructions","main":"lib/parser.js","types":"index.d.ts","typesVersions":{"<4.1":{"*":["types/ts3/*"]}},"directories":{"test":"test"},"scripts":{"test:tsd":"tsd","test:unit":"TZ=UTC tap ./test/*.js","test:cover":"TZ=UTC tap --coverage-report=html ./test/*.js","lint":"eslint .","lint:fix":"eslint --fix .","test":"npm run lint && npm run test:unit && npm run test:tsd"},"repository":{"type":"git","url":"https://github.com/harrisiirak/cron-parser.git"},"keywords":["cron","crontab","parser"],"author":"Harri Siirak","contributors":["Nicholas Clawson","Daniel Prentis <daniel@salsitasoft.com>","Renault John Lecoultre","Richard Astbury <richard.astbury@gmail.com>","Meaglin Wasabi <Meaglin.wasabi@gmail.com>","Mike Kusold <hello@mikekusold.com>","Alex Kit <alex.kit@atmajs.com>","Santiago Gimeno <santiago.gimeno@gmail.com>","Daniel <darc.tec@gmail.com>","Christian Steininger <christian.steininger.cs@gmail.com>","Mykola Piskovyi <m.piskovyi@gmail.com>","Brian Vaughn <brian.david.vaughn@gmail.com>","Nicholas Clawson <nickclaw@gmail.com>","Yasuhiroki <yasuhiroki.duck@gmail.com>","Nicholas Clawson <nickclaw@gmail.com>","Brendan Warkentin <faazshift@gmail.com>","Charlie Fish <fishcharlie.code@gmail.com>","Ian Graves <ian+diskimage@iangrav.es>","Andy Thompson <me@andytson.com>","Regev Brody <regevbr@gmail.com>"],"license":"MIT","dependencies":{"luxon":"^1.28.0"},"devDependencies":{"eslint":"^8.2.0","sinon":"^10.0.0","tap":"^16.0.1","tsd":"^0.19.0"},"engines":{"node":">=0.8"},"browser":{"fs":false},"tap":{"check-coverage":false},"tsd":{"directory":"test","compilerOptions":{"lib":["es2017","dom"]}},"_lastModified":"2024-06-12T10:07:36.871Z"}
@@ -1 +1 @@
1
- {"name":"lru-cache","description":"A cache object that deletes the least-recently-used items.","version":"8.0.5","author":"Isaac Z. Schlueter <i@izs.me>","keywords":["mru","lru","cache"],"sideEffects":false,"scripts":{"build":"npm run prepare","preprepare":"rm -rf dist","prepare":"tsc -p tsconfig.json && tsc -p tsconfig-esm.json","postprepare":"bash fixup.sh","pretest":"npm run prepare","presnap":"npm run prepare","test":"c8 tap","snap":"c8 tap","preversion":"npm test","postversion":"npm publish","prepublishOnly":"git push origin --follow-tags","format":"prettier --write .","typedoc":"typedoc --tsconfig tsconfig-esm.json ./src/*.ts","benchmark-results-typedoc":"bash scripts/benchmark-results-typedoc.sh","prebenchmark":"npm run prepare","benchmark":"make -C benchmark","preprofile":"npm run prepare","profile":"make -C benchmark profile"},"main":"./dist/cjs/index-cjs.js","module":"./dist/mjs/index.js","types":"./dist/mjs/index.d.ts","exports":{"./min":{"import":{"types":"./dist/mjs/index.d.ts","default":"./dist/mjs/index.min.js"},"require":{"types":"./dist/cjs/index.d.ts","default":"./dist/cjs/index.min.js"}},".":{"import":{"types":"./dist/mjs/index.d.ts","default":"./dist/mjs/index.js"},"require":{"types":"./dist/cjs/index.d.ts","default":"./dist/cjs/index-cjs.js"}}},"repository":"git://github.com/isaacs/node-lru-cache.git","devDependencies":{"@size-limit/preset-small-lib":"^7.0.8","@types/node":"^17.0.31","@types/tap":"^15.0.6","benchmark":"^2.1.4","c8":"^7.11.2","clock-mock":"^1.0.6","esbuild":"^0.17.11","eslint-config-prettier":"^8.5.0","marked":"^4.2.12","mkdirp":"^2.1.5","prettier":"^2.6.2","size-limit":"^7.0.8","tap":"^16.3.4","ts-node":"^10.7.0","tslib":"^2.4.0","typedoc":"^0.23.24","typescript":"^4.6.4"},"license":"ISC","files":["dist"],"engines":{"node":">=16.14"},"prettier":{"semi":false,"printWidth":70,"tabWidth":2,"useTabs":false,"singleQuote":true,"jsxSingleQuote":false,"bracketSameLine":true,"arrowParens":"avoid","endOfLine":"lf"},"tap":{"coverage":false,"node-arg":["--expose-gc","--no-warnings","--loader","ts-node/esm"],"ts":false},"size-limit":[{"path":"./dist/mjs/index.js"}],"_lastModified":"2024-06-12T05:27:08.186Z"}
1
+ {"name":"lru-cache","description":"A cache object that deletes the least-recently-used items.","version":"8.0.5","author":"Isaac Z. Schlueter <i@izs.me>","keywords":["mru","lru","cache"],"sideEffects":false,"scripts":{"build":"npm run prepare","preprepare":"rm -rf dist","prepare":"tsc -p tsconfig.json && tsc -p tsconfig-esm.json","postprepare":"bash fixup.sh","pretest":"npm run prepare","presnap":"npm run prepare","test":"c8 tap","snap":"c8 tap","preversion":"npm test","postversion":"npm publish","prepublishOnly":"git push origin --follow-tags","format":"prettier --write .","typedoc":"typedoc --tsconfig tsconfig-esm.json ./src/*.ts","benchmark-results-typedoc":"bash scripts/benchmark-results-typedoc.sh","prebenchmark":"npm run prepare","benchmark":"make -C benchmark","preprofile":"npm run prepare","profile":"make -C benchmark profile"},"main":"./dist/cjs/index-cjs.js","module":"./dist/mjs/index.js","types":"./dist/mjs/index.d.ts","exports":{"./min":{"import":{"types":"./dist/mjs/index.d.ts","default":"./dist/mjs/index.min.js"},"require":{"types":"./dist/cjs/index.d.ts","default":"./dist/cjs/index.min.js"}},".":{"import":{"types":"./dist/mjs/index.d.ts","default":"./dist/mjs/index.js"},"require":{"types":"./dist/cjs/index.d.ts","default":"./dist/cjs/index-cjs.js"}}},"repository":"git://github.com/isaacs/node-lru-cache.git","devDependencies":{"@size-limit/preset-small-lib":"^7.0.8","@types/node":"^17.0.31","@types/tap":"^15.0.6","benchmark":"^2.1.4","c8":"^7.11.2","clock-mock":"^1.0.6","esbuild":"^0.17.11","eslint-config-prettier":"^8.5.0","marked":"^4.2.12","mkdirp":"^2.1.5","prettier":"^2.6.2","size-limit":"^7.0.8","tap":"^16.3.4","ts-node":"^10.7.0","tslib":"^2.4.0","typedoc":"^0.23.24","typescript":"^4.6.4"},"license":"ISC","files":["dist"],"engines":{"node":">=16.14"},"prettier":{"semi":false,"printWidth":70,"tabWidth":2,"useTabs":false,"singleQuote":true,"jsxSingleQuote":false,"bracketSameLine":true,"arrowParens":"avoid","endOfLine":"lf"},"tap":{"coverage":false,"node-arg":["--expose-gc","--no-warnings","--loader","ts-node/esm"],"ts":false},"size-limit":[{"path":"./dist/mjs/index.js"}],"_lastModified":"2024-06-12T10:07:36.514Z"}
package/package.json CHANGED
@@ -4,13 +4,13 @@
4
4
  "displayName.zh-CN": "工作流",
5
5
  "description": "A powerful BPM tool that provides foundational support for business automation, with the capability to extend unlimited triggers and nodes.",
6
6
  "description.zh-CN": "一个强大的 BPM 工具,为业务自动化提供基础支持,并且可任意扩展更多的触发器和节点。",
7
- "version": "1.2.1-alpha",
7
+ "version": "1.2.2-alpha",
8
8
  "license": "AGPL-3.0",
9
9
  "main": "./dist/server/index.js",
10
10
  "homepage": "https://docs.nocobase.com/handbook/workflow",
11
11
  "homepage.zh-CN": "https://docs-cn.nocobase.com/handbook/workflow",
12
12
  "dependencies": {
13
- "@nocobase/plugin-workflow-test": "1.2.1-alpha"
13
+ "@nocobase/plugin-workflow-test": "1.2.2-alpha"
14
14
  },
15
15
  "devDependencies": {
16
16
  "@ant-design/icons": "5.x",
@@ -44,7 +44,7 @@
44
44
  "@nocobase/test": "1.x",
45
45
  "@nocobase/utils": "1.x"
46
46
  },
47
- "gitHead": "0171192d82cb52de02c9ab6d66a03843d5153c76",
47
+ "gitHead": "d968839548b92e4d4c20614fdb44a17494f84439",
48
48
  "keywords": [
49
49
  "Workflow"
50
50
  ]