@nocobase/flow-engine 2.1.0-beta.38 → 2.1.0-beta.41
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.
|
@@ -38,7 +38,13 @@ export declare class DataSourceManager {
|
|
|
38
38
|
}>) => void;
|
|
39
39
|
addFieldInterfaceComponentOption?: (name: string, option: any) => void;
|
|
40
40
|
addFieldInterfaceOperator?: (name: string, operator: any) => void;
|
|
41
|
+
registerFieldFilterOperator?: (operator: any) => void;
|
|
42
|
+
registerFieldFilterOperatorGroup?: (name: string, operators?: any[]) => void;
|
|
43
|
+
addFieldFilterOperatorsToGroup?: (name: string, operators?: any[]) => void;
|
|
41
44
|
getFieldInterface?: (name: string) => any;
|
|
45
|
+
registerFieldInterfaceConfigure?: (options: unknown) => void;
|
|
46
|
+
getFieldInterfaceConfigure?: (name: string, collectionInfo?: unknown) => unknown;
|
|
47
|
+
getFieldInterfaceConfigureProperties?: (name: string, collectionInfo?: any) => Record<string, any>;
|
|
42
48
|
};
|
|
43
49
|
loaders: Map<string, DataSourceLoader>;
|
|
44
50
|
loadedKeys: Set<string>;
|
|
@@ -56,6 +62,9 @@ export declare class DataSourceManager {
|
|
|
56
62
|
}>): void;
|
|
57
63
|
addFieldInterfaceComponentOption(name: string, option: any): void;
|
|
58
64
|
addFieldInterfaceOperator(name: string, operator: any): void;
|
|
65
|
+
registerFieldFilterOperator(operator: any): void;
|
|
66
|
+
registerFieldFilterOperatorGroup(name: string, operators?: any[]): void;
|
|
67
|
+
addFieldFilterOperatorsToGroup(name: string, operators?: any[]): void;
|
|
59
68
|
registerLoader(key: string, loader: DataSourceLoader): void;
|
|
60
69
|
removeLoader(key: string): void;
|
|
61
70
|
addDataSource(ds: DataSource | DataSourceOptions): void;
|
package/lib/data-source/index.js
CHANGED
|
@@ -89,6 +89,18 @@ const _DataSourceManager = class _DataSourceManager {
|
|
|
89
89
|
var _a, _b;
|
|
90
90
|
(_b = (_a = this.collectionFieldInterfaceManager) == null ? void 0 : _a.addFieldInterfaceOperator) == null ? void 0 : _b.call(_a, name, operator);
|
|
91
91
|
}
|
|
92
|
+
registerFieldFilterOperator(operator) {
|
|
93
|
+
var _a, _b;
|
|
94
|
+
(_b = (_a = this.collectionFieldInterfaceManager) == null ? void 0 : _a.registerFieldFilterOperator) == null ? void 0 : _b.call(_a, operator);
|
|
95
|
+
}
|
|
96
|
+
registerFieldFilterOperatorGroup(name, operators = []) {
|
|
97
|
+
var _a, _b;
|
|
98
|
+
(_b = (_a = this.collectionFieldInterfaceManager) == null ? void 0 : _a.registerFieldFilterOperatorGroup) == null ? void 0 : _b.call(_a, name, operators);
|
|
99
|
+
}
|
|
100
|
+
addFieldFilterOperatorsToGroup(name, operators = []) {
|
|
101
|
+
var _a, _b;
|
|
102
|
+
(_b = (_a = this.collectionFieldInterfaceManager) == null ? void 0 : _a.addFieldFilterOperatorsToGroup) == null ? void 0 : _b.call(_a, name, operators);
|
|
103
|
+
}
|
|
92
104
|
registerLoader(key, loader) {
|
|
93
105
|
this.loaders.set(key, loader);
|
|
94
106
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nocobase/flow-engine",
|
|
3
|
-
"version": "2.1.0-beta.
|
|
3
|
+
"version": "2.1.0-beta.41",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "A standalone flow engine for NocoBase, managing workflows, models, and actions.",
|
|
6
6
|
"main": "lib/index.js",
|
|
@@ -8,8 +8,8 @@
|
|
|
8
8
|
"dependencies": {
|
|
9
9
|
"@formily/antd-v5": "1.x",
|
|
10
10
|
"@formily/reactive": "2.x",
|
|
11
|
-
"@nocobase/sdk": "2.1.0-beta.
|
|
12
|
-
"@nocobase/shared": "2.1.0-beta.
|
|
11
|
+
"@nocobase/sdk": "2.1.0-beta.41",
|
|
12
|
+
"@nocobase/shared": "2.1.0-beta.41",
|
|
13
13
|
"ahooks": "^3.7.2",
|
|
14
14
|
"axios": "^1.7.0",
|
|
15
15
|
"dayjs": "^1.11.9",
|
|
@@ -37,5 +37,5 @@
|
|
|
37
37
|
],
|
|
38
38
|
"author": "NocoBase Team",
|
|
39
39
|
"license": "Apache-2.0",
|
|
40
|
-
"gitHead": "
|
|
40
|
+
"gitHead": "ea3f966811146edb13c9e8016bf4cdc81597a003"
|
|
41
41
|
}
|
package/src/data-source/index.ts
CHANGED
|
@@ -37,7 +37,13 @@ export class DataSourceManager {
|
|
|
37
37
|
addFieldInterfaceGroups?: (groups: Record<string, { label: string; order?: number }>) => void;
|
|
38
38
|
addFieldInterfaceComponentOption?: (name: string, option: any) => void;
|
|
39
39
|
addFieldInterfaceOperator?: (name: string, operator: any) => void;
|
|
40
|
+
registerFieldFilterOperator?: (operator: any) => void;
|
|
41
|
+
registerFieldFilterOperatorGroup?: (name: string, operators?: any[]) => void;
|
|
42
|
+
addFieldFilterOperatorsToGroup?: (name: string, operators?: any[]) => void;
|
|
40
43
|
getFieldInterface?: (name: string) => any;
|
|
44
|
+
registerFieldInterfaceConfigure?: (options: unknown) => void;
|
|
45
|
+
getFieldInterfaceConfigure?: (name: string, collectionInfo?: unknown) => unknown;
|
|
46
|
+
getFieldInterfaceConfigureProperties?: (name: string, collectionInfo?: any) => Record<string, any>;
|
|
41
47
|
};
|
|
42
48
|
loaders = new Map<string, DataSourceLoader>();
|
|
43
49
|
loadedKeys = new Set<string>();
|
|
@@ -77,6 +83,18 @@ export class DataSourceManager {
|
|
|
77
83
|
this.collectionFieldInterfaceManager?.addFieldInterfaceOperator?.(name, operator);
|
|
78
84
|
}
|
|
79
85
|
|
|
86
|
+
registerFieldFilterOperator(operator: any) {
|
|
87
|
+
this.collectionFieldInterfaceManager?.registerFieldFilterOperator?.(operator);
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
registerFieldFilterOperatorGroup(name: string, operators: any[] = []) {
|
|
91
|
+
this.collectionFieldInterfaceManager?.registerFieldFilterOperatorGroup?.(name, operators);
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
addFieldFilterOperatorsToGroup(name: string, operators: any[] = []) {
|
|
95
|
+
this.collectionFieldInterfaceManager?.addFieldFilterOperatorsToGroup?.(name, operators);
|
|
96
|
+
}
|
|
97
|
+
|
|
80
98
|
registerLoader(key: string, loader: DataSourceLoader) {
|
|
81
99
|
this.loaders.set(key, loader);
|
|
82
100
|
}
|