@nocobase/plugin-flow-engine 2.4.0-alpha.17 → 2.4.0-alpha.19
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/dist/ai/docs/runjs/context/exit-all.md +3 -27
- package/dist/ai/docs/runjs/context/exit.md +5 -29
- package/dist/externalVersion.js +9 -9
- package/dist/locale/en-US.json +1 -0
- package/dist/locale/index.d.ts +2 -0
- package/dist/locale/zh-CN.json +1 -0
- package/dist/node_modules/@ant-design/icons-svg/package.json +1 -1
- package/dist/node_modules/acorn/package.json +1 -1
- package/dist/node_modules/acorn-jsx/package.json +1 -1
- package/dist/node_modules/acorn-walk/package.json +1 -1
- package/dist/node_modules/liquidjs/package.json +1 -1
- package/dist/node_modules/ses/package.json +1 -1
- package/dist/node_modules/zod/package.json +1 -1
- package/dist/server/repository.d.ts +6 -0
- package/dist/server/repository.js +16 -0
- package/dist/server/server.js +9 -0
- package/package.json +2 -2
|
@@ -12,7 +12,7 @@ Terminates the current event flow and all subsequent event flows triggered in th
|
|
|
12
12
|
| **Linkage Rules** | When linkage validation fails, the current linkage and subsequent linkages triggered by the same event must be terminated. |
|
|
13
13
|
| **Action Events** | Pre-action validation fails (e.g., permission check before deletion), requiring the prevention of the main action and subsequent steps. |
|
|
14
14
|
|
|
15
|
-
>
|
|
15
|
+
> `ctx.exit()` / `ctx.exitAll()` — Both calls stop the current step and skip the remaining flows in the same sequential event dispatch. Flows already running in parallel continue.
|
|
16
16
|
|
|
17
17
|
## Type Definition
|
|
18
18
|
|
|
@@ -22,13 +22,6 @@ exitAll(): never;
|
|
|
22
22
|
|
|
23
23
|
Calling `ctx.exitAll()` throws an internal `FlowExitAllException`, which is caught by the FlowEngine to stop the current event flow instance and subsequent event flows under the same event. Once called, the remaining statements in the current JS code will not be executed.
|
|
24
24
|
|
|
25
|
-
## Comparison with ctx.exit()
|
|
26
|
-
|
|
27
|
-
| Method | Scope |
|
|
28
|
-
|------|----------|
|
|
29
|
-
| `ctx.exit()` | Only terminates the current event flow; subsequent event flows are unaffected. |
|
|
30
|
-
| `ctx.exitAll()` | Terminates the current event flow and aborts subsequent event flows executed **sequentially** under the same event. |
|
|
31
|
-
|
|
32
25
|
## Execution Mode
|
|
33
26
|
|
|
34
27
|
- **Sequential Execution**: Event flows under the same event are executed in order. After any event flow calls `ctx.exitAll()`, subsequent event flows will not execute.
|
|
@@ -57,22 +50,6 @@ if (!canDelete) {
|
|
|
57
50
|
}
|
|
58
51
|
```
|
|
59
52
|
|
|
60
|
-
### Choosing between ctx.exit() and ctx.exitAll()
|
|
61
|
-
|
|
62
|
-
```ts
|
|
63
|
-
// Only the current event flow needs to exit -> Use ctx.exit()
|
|
64
|
-
if (!params.valid) {
|
|
65
|
-
ctx.message.error('Invalid parameters');
|
|
66
|
-
ctx.exit(); // Subsequent event flows are unaffected
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
// Need to terminate all subsequent event flows under the current event -> Use ctx.exitAll()
|
|
70
|
-
if (!ctx.model?.context?.getPermission?.()) {
|
|
71
|
-
ctx.notification.warning({ message: 'Insufficient permissions' });
|
|
72
|
-
ctx.exitAll(); // Both the main event flow and subsequent event flows under the same event are terminated
|
|
73
|
-
}
|
|
74
|
-
```
|
|
75
|
-
|
|
76
53
|
### Prompt before terminating
|
|
77
54
|
|
|
78
55
|
```ts
|
|
@@ -86,11 +63,10 @@ if (!isValidInput(ctx.form?.getValues?.())) {
|
|
|
86
63
|
|
|
87
64
|
- After calling `ctx.exitAll()`, subsequent code in the current JS will not execute. It is recommended to explain the reason to the user via `ctx.message`, `ctx.notification`, or a modal before calling it.
|
|
88
65
|
- Business code usually does not need to catch `FlowExitAllException`; let the FlowEngine handle it.
|
|
89
|
-
- If you only need to stop the current event flow without affecting subsequent ones, use `ctx.exit()`.
|
|
90
66
|
- In parallel mode, `ctx.exitAll()` only terminates the current event flow and does not interrupt other concurrent event flows.
|
|
91
67
|
|
|
92
68
|
## Related
|
|
93
69
|
|
|
94
|
-
- [ctx.exit()](./exit.md)
|
|
70
|
+
- [ctx.exit()](./exit.md)
|
|
95
71
|
- [ctx.message](./message.md): Message prompts
|
|
96
|
-
- [ctx.modal](./modal.md): Confirmation modal
|
|
72
|
+
- [ctx.modal](./modal.md): Confirmation modal
|
|
@@ -12,7 +12,7 @@ Terminates the execution of the current event flow; subsequent steps will not ru
|
|
|
12
12
|
| **Linkage Rules** | In field linkages, filter linkages, etc., terminates the current event flow when validation fails or execution needs to be skipped. |
|
|
13
13
|
| **Action Events** | In custom actions (e.g., delete confirmation, pre-save validation), exits when the user cancels or validation fails. |
|
|
14
14
|
|
|
15
|
-
>
|
|
15
|
+
> `ctx.exit()` / `ctx.exitAll()` — Both calls stop the current step and skip the remaining flows in the same sequential event dispatch. Flows already running in parallel continue.
|
|
16
16
|
|
|
17
17
|
## Type Definition
|
|
18
18
|
|
|
@@ -20,14 +20,7 @@ Terminates the execution of the current event flow; subsequent steps will not ru
|
|
|
20
20
|
exit(): never;
|
|
21
21
|
```
|
|
22
22
|
|
|
23
|
-
Calling `ctx.exit()` throws an internal `
|
|
24
|
-
|
|
25
|
-
## Comparison with ctx.exitAll()
|
|
26
|
-
|
|
27
|
-
| Method | Scope of Effect |
|
|
28
|
-
|------|----------|
|
|
29
|
-
| `ctx.exit()` | Terminates only the current event flow; subsequent event flows are unaffected. |
|
|
30
|
-
| `ctx.exitAll()` | Terminates the current event flow and aborts subsequent event flows under the same event that are set to **execute sequentially**. |
|
|
23
|
+
Calling `ctx.exit()` throws an internal `FlowExitAllException`, which is caught by the FlowEngine to stop the current event flow execution. Once called, the remaining statements in the current JS code will not execute.
|
|
31
24
|
|
|
32
25
|
## Examples
|
|
33
26
|
|
|
@@ -62,22 +55,6 @@ if (!record || record.status !== 'draft') {
|
|
|
62
55
|
}
|
|
63
56
|
```
|
|
64
57
|
|
|
65
|
-
### Choosing Between ctx.exit() and ctx.exitAll()
|
|
66
|
-
|
|
67
|
-
```ts
|
|
68
|
-
// Only the current event flow needs to exit → Use ctx.exit()
|
|
69
|
-
if (!params.valid) {
|
|
70
|
-
ctx.message.error('Invalid parameters');
|
|
71
|
-
ctx.exit(); // Other event flows are unaffected
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
// Need to terminate all subsequent event flows under the current event → Use ctx.exitAll()
|
|
75
|
-
if (!ctx.model?.context?.getPermission?.()) {
|
|
76
|
-
ctx.notification.warning({ message: 'Insufficient permissions' });
|
|
77
|
-
ctx.exitAll(); // Both the current event flow and subsequent event flows under the same event are terminated
|
|
78
|
-
}
|
|
79
|
-
```
|
|
80
|
-
|
|
81
58
|
### Exit Based on User Choice After Modal Confirmation
|
|
82
59
|
|
|
83
60
|
```ts
|
|
@@ -94,11 +71,10 @@ if (!ok) {
|
|
|
94
71
|
## Notes
|
|
95
72
|
|
|
96
73
|
- After calling `ctx.exit()`, subsequent code in the current JS will not execute; it is recommended to explain the reason to the user via `ctx.message`, `ctx.notification`, or a modal before calling it.
|
|
97
|
-
- There is usually no need to catch `
|
|
98
|
-
- If you need to terminate all subsequent event flows under the current event, use `ctx.exitAll()`.
|
|
74
|
+
- There is usually no need to catch `FlowExitAllException` in business code; let the FlowEngine handle it.
|
|
99
75
|
|
|
100
76
|
## Related
|
|
101
77
|
|
|
102
|
-
- [ctx.exitAll()](./exit-all.md)
|
|
78
|
+
- [ctx.exitAll()](./exit-all.md)
|
|
103
79
|
- [ctx.message](./message.md): Message prompts.
|
|
104
|
-
- [ctx.modal](./modal.md): Confirmation modals.
|
|
80
|
+
- [ctx.modal](./modal.md): Confirmation modals.
|
package/dist/externalVersion.js
CHANGED
|
@@ -8,16 +8,16 @@
|
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
module.exports = {
|
|
11
|
-
"@nocobase/client": "2.4.0-alpha.
|
|
11
|
+
"@nocobase/client": "2.4.0-alpha.19",
|
|
12
12
|
"lodash": "4.18.1",
|
|
13
|
-
"@nocobase/database": "2.4.0-alpha.
|
|
14
|
-
"@nocobase/data-source-manager": "2.4.0-alpha.
|
|
15
|
-
"@nocobase/resourcer": "2.4.0-alpha.
|
|
16
|
-
"@nocobase/server": "2.4.0-alpha.
|
|
17
|
-
"@nocobase/utils": "2.4.0-alpha.
|
|
18
|
-
"@nocobase/cache": "2.4.0-alpha.
|
|
19
|
-
"@nocobase/actions": "2.4.0-alpha.
|
|
13
|
+
"@nocobase/database": "2.4.0-alpha.19",
|
|
14
|
+
"@nocobase/data-source-manager": "2.4.0-alpha.19",
|
|
15
|
+
"@nocobase/resourcer": "2.4.0-alpha.19",
|
|
16
|
+
"@nocobase/server": "2.4.0-alpha.19",
|
|
17
|
+
"@nocobase/utils": "2.4.0-alpha.19",
|
|
18
|
+
"@nocobase/cache": "2.4.0-alpha.19",
|
|
19
|
+
"@nocobase/actions": "2.4.0-alpha.19",
|
|
20
20
|
"sequelize": "6.35.2",
|
|
21
21
|
"@formily/json-schema": "2.3.7",
|
|
22
|
-
"@nocobase/ai": "2.4.0-alpha.
|
|
22
|
+
"@nocobase/ai": "2.4.0-alpha.19"
|
|
23
23
|
};
|
package/dist/locale/en-US.json
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
+
"The association target key is missing or invalid.": "The association target key is missing or invalid.",
|
|
2
3
|
"Add": "Add",
|
|
3
4
|
"Are you sure you want to perform the action?": "Are you sure you want to perform the action?",
|
|
4
5
|
"Are you sure you want to delete this item? This action cannot be undone.": "Are you sure you want to delete this item? This action cannot be undone.",
|
package/dist/locale/index.d.ts
CHANGED
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
*/
|
|
9
9
|
export declare const locales: {
|
|
10
10
|
'en-US': {
|
|
11
|
+
"The association target key is missing or invalid.": string;
|
|
11
12
|
Add: string;
|
|
12
13
|
"Are you sure you want to perform the action?": string;
|
|
13
14
|
"Are you sure you want to delete this item? This action cannot be undone.": string;
|
|
@@ -92,6 +93,7 @@ export declare const locales: {
|
|
|
92
93
|
"RunJS deprecated removedIn": string;
|
|
93
94
|
};
|
|
94
95
|
'zh-CN': {
|
|
96
|
+
"The association target key is missing or invalid.": string;
|
|
95
97
|
Add: string;
|
|
96
98
|
"Are you sure you want to perform the action?": string;
|
|
97
99
|
"Are you sure you want to delete this item? This action cannot be undone.": string;
|
package/dist/locale/zh-CN.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"name":"@ant-design/icons-svg","version":"4.3.1","sideEffects":false,"description":"Abstract nodes for ant design icons.","contributors":["HeskeyBaozi <hezhiyu233@foxmail.com>"],"homepage":"https://github.com/ant-design/ant-design-icons/","license":"MIT","main":"lib/index.js","module":"es/index.js","files":["lib","es","inline-svg","inline-namespaced-svg"],"repository":{"type":"git","url":"git+https://github.com/ant-design/ant-design-icons.git"},"scripts":{"g":"npm run generate","generate":"cross-env NODE_ENV=production gulp --require ts-node/register/transpile-only","type-check":"tsc --noEmit","build:es":"tsc --project tsconfig.build.json --module esnext --outDir es","build:lib":"tsc --project tsconfig.build.json --module commonjs --outDir lib","build":"cross-env NODE_ENV=production && npm run build:es && npm run build:lib","test":"cross-env NODE_ENV=test && npm run test:unit","test:unit":"jest","prepublishOnly":"npm run test && npm run g && npm run build && npm run type-check && npm run digest","digest":"node scripts/digest.js"},"bugs":{"url":"https://github.com/ant-design/ant-design-icons/issues"},"devDependencies":{"@babel/core":"^7.8.6","@babel/preset-env":"^7.8.6","@babel/preset-typescript":"^7.8.3","@rgrove/parse-xml":"^2.0.2","@types/gulp":"^4.0.6","@types/gulp-concat":"^0.0.32","@types/gulp-rename":"^0.0.33","@types/jest":"^25.1.3","@types/lodash.camelcase":"^4.3.6","@types/lodash.template":"^4.4.6","@types/lodash.upperfirst":"^4.3.6","@types/node":"^13.9.3","@types/ramda":"^0.26.43","@types/rgrove__parse-xml":"^1.1.0","@types/svgo":"^1.3.1","@types/through2":"^2.0.34","@typescript-eslint/eslint-plugin":"^2.21.0","@typescript-eslint/parser":"^2.21.0","babel-jest":"^25.1.0","cross-env":"^7.0.0","del":"^5.1.0","eslint":"^7.16.0","globby":"^11.0.0","gulp":"^4.0.2","gulp-clone":"^2.0.1","gulp-concat":"^2.6.1","gulp-header":"^2.0.9","gulp-rename":"^2.0.0","jest":"^25.1.0","lodash.camelcase":"^4.3.0","lodash.template":"^4.5.0","lodash.upperfirst":"^4.3.1","ramda":"^0.27.0","svgo":"^1.3.2","through2":"^3.0.1","ts-node":"^8.6.2","typescript":"^4.0.0","vinyl":"^2.2.0"},"publishConfig":{"access":"public","registry":"https://registry.npmjs.org"},"_lastModified":"2026-11-
|
|
1
|
+
{"name":"@ant-design/icons-svg","version":"4.3.1","sideEffects":false,"description":"Abstract nodes for ant design icons.","contributors":["HeskeyBaozi <hezhiyu233@foxmail.com>"],"homepage":"https://github.com/ant-design/ant-design-icons/","license":"MIT","main":"lib/index.js","module":"es/index.js","files":["lib","es","inline-svg","inline-namespaced-svg"],"repository":{"type":"git","url":"git+https://github.com/ant-design/ant-design-icons.git"},"scripts":{"g":"npm run generate","generate":"cross-env NODE_ENV=production gulp --require ts-node/register/transpile-only","type-check":"tsc --noEmit","build:es":"tsc --project tsconfig.build.json --module esnext --outDir es","build:lib":"tsc --project tsconfig.build.json --module commonjs --outDir lib","build":"cross-env NODE_ENV=production && npm run build:es && npm run build:lib","test":"cross-env NODE_ENV=test && npm run test:unit","test:unit":"jest","prepublishOnly":"npm run test && npm run g && npm run build && npm run type-check && npm run digest","digest":"node scripts/digest.js"},"bugs":{"url":"https://github.com/ant-design/ant-design-icons/issues"},"devDependencies":{"@babel/core":"^7.8.6","@babel/preset-env":"^7.8.6","@babel/preset-typescript":"^7.8.3","@rgrove/parse-xml":"^2.0.2","@types/gulp":"^4.0.6","@types/gulp-concat":"^0.0.32","@types/gulp-rename":"^0.0.33","@types/jest":"^25.1.3","@types/lodash.camelcase":"^4.3.6","@types/lodash.template":"^4.4.6","@types/lodash.upperfirst":"^4.3.6","@types/node":"^13.9.3","@types/ramda":"^0.26.43","@types/rgrove__parse-xml":"^1.1.0","@types/svgo":"^1.3.1","@types/through2":"^2.0.34","@typescript-eslint/eslint-plugin":"^2.21.0","@typescript-eslint/parser":"^2.21.0","babel-jest":"^25.1.0","cross-env":"^7.0.0","del":"^5.1.0","eslint":"^7.16.0","globby":"^11.0.0","gulp":"^4.0.2","gulp-clone":"^2.0.1","gulp-concat":"^2.6.1","gulp-header":"^2.0.9","gulp-rename":"^2.0.0","jest":"^25.1.0","lodash.camelcase":"^4.3.0","lodash.template":"^4.5.0","lodash.upperfirst":"^4.3.1","ramda":"^0.27.0","svgo":"^1.3.2","through2":"^3.0.1","ts-node":"^8.6.2","typescript":"^4.0.0","vinyl":"^2.2.0"},"publishConfig":{"access":"public","registry":"https://registry.npmjs.org"},"_lastModified":"2026-11-24T11:21:07.247Z"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"name":"acorn","description":"ECMAScript parser","homepage":"https://github.com/acornjs/acorn","main":"dist/acorn.js","types":"dist/acorn.d.ts","module":"dist/acorn.mjs","exports":{".":[{"import":"./dist/acorn.mjs","require":"./dist/acorn.js","default":"./dist/acorn.js"},"./dist/acorn.js"],"./package.json":"./package.json"},"version":"8.11.2","engines":{"node":">=0.4.0"},"maintainers":[{"name":"Marijn Haverbeke","email":"marijnh@gmail.com","web":"https://marijnhaverbeke.nl"},{"name":"Ingvar Stepanyan","email":"me@rreverser.com","web":"https://rreverser.com/"},{"name":"Adrian Heine","web":"http://adrianheine.de"}],"repository":{"type":"git","url":"https://github.com/acornjs/acorn.git"},"license":"MIT","scripts":{"prepare":"cd ..; npm run build:main"},"bin":{"acorn":"./bin/acorn"},"_lastModified":"2026-11-
|
|
1
|
+
{"name":"acorn","description":"ECMAScript parser","homepage":"https://github.com/acornjs/acorn","main":"dist/acorn.js","types":"dist/acorn.d.ts","module":"dist/acorn.mjs","exports":{".":[{"import":"./dist/acorn.mjs","require":"./dist/acorn.js","default":"./dist/acorn.js"},"./dist/acorn.js"],"./package.json":"./package.json"},"version":"8.11.2","engines":{"node":">=0.4.0"},"maintainers":[{"name":"Marijn Haverbeke","email":"marijnh@gmail.com","web":"https://marijnhaverbeke.nl"},{"name":"Ingvar Stepanyan","email":"me@rreverser.com","web":"https://rreverser.com/"},{"name":"Adrian Heine","web":"http://adrianheine.de"}],"repository":{"type":"git","url":"https://github.com/acornjs/acorn.git"},"license":"MIT","scripts":{"prepare":"cd ..; npm run build:main"},"bin":{"acorn":"./bin/acorn"},"_lastModified":"2026-11-24T11:21:08.181Z"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"name":"acorn-jsx","description":"Modern, fast React.js JSX parser","homepage":"https://github.com/acornjs/acorn-jsx","version":"5.3.2","maintainers":[{"name":"Ingvar Stepanyan","email":"me@rreverser.com","web":"http://rreverser.com/"}],"repository":{"type":"git","url":"https://github.com/acornjs/acorn-jsx"},"license":"MIT","scripts":{"test":"node test/run.js"},"peerDependencies":{"acorn":"^6.0.0 || ^7.0.0 || ^8.0.0"},"devDependencies":{"acorn":"^8.0.1"},"_lastModified":"2026-11-
|
|
1
|
+
{"name":"acorn-jsx","description":"Modern, fast React.js JSX parser","homepage":"https://github.com/acornjs/acorn-jsx","version":"5.3.2","maintainers":[{"name":"Ingvar Stepanyan","email":"me@rreverser.com","web":"http://rreverser.com/"}],"repository":{"type":"git","url":"https://github.com/acornjs/acorn-jsx"},"license":"MIT","scripts":{"test":"node test/run.js"},"peerDependencies":{"acorn":"^6.0.0 || ^7.0.0 || ^8.0.0"},"devDependencies":{"acorn":"^8.0.1"},"_lastModified":"2026-11-24T11:21:09.128Z"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"name":"acorn-walk","description":"ECMAScript (ESTree) AST walker","homepage":"https://github.com/acornjs/acorn","main":"dist/walk.js","types":"dist/walk.d.ts","module":"dist/walk.mjs","exports":{".":[{"import":"./dist/walk.mjs","require":"./dist/walk.js","default":"./dist/walk.js"},"./dist/walk.js"],"./package.json":"./package.json"},"version":"8.3.4","engines":{"node":">=0.4.0"},"dependencies":{"acorn":"^8.11.0"},"maintainers":[{"name":"Marijn Haverbeke","email":"marijnh@gmail.com","web":"https://marijnhaverbeke.nl"},{"name":"Ingvar Stepanyan","email":"me@rreverser.com","web":"https://rreverser.com/"},{"name":"Adrian Heine","web":"http://adrianheine.de"}],"repository":{"type":"git","url":"https://github.com/acornjs/acorn.git"},"scripts":{"prepare":"cd ..; npm run build:walk"},"license":"MIT","_lastModified":"2026-11-
|
|
1
|
+
{"name":"acorn-walk","description":"ECMAScript (ESTree) AST walker","homepage":"https://github.com/acornjs/acorn","main":"dist/walk.js","types":"dist/walk.d.ts","module":"dist/walk.mjs","exports":{".":[{"import":"./dist/walk.mjs","require":"./dist/walk.js","default":"./dist/walk.js"},"./dist/walk.js"],"./package.json":"./package.json"},"version":"8.3.4","engines":{"node":">=0.4.0"},"dependencies":{"acorn":"^8.11.0"},"maintainers":[{"name":"Marijn Haverbeke","email":"marijnh@gmail.com","web":"https://marijnhaverbeke.nl"},{"name":"Ingvar Stepanyan","email":"me@rreverser.com","web":"https://rreverser.com/"},{"name":"Adrian Heine","web":"http://adrianheine.de"}],"repository":{"type":"git","url":"https://github.com/acornjs/acorn.git"},"scripts":{"prepare":"cd ..; npm run build:walk"},"license":"MIT","_lastModified":"2026-11-24T11:21:09.247Z"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"name":"liquidjs","version":"10.23.0","sideEffects":false,"description":"A simple, expressive and safe Shopify / Github Pages compatible template engine in pure JavaScript.","main":"dist/liquid.node.js","module":"dist/liquid.node.mjs","es2015":"dist/liquid.browser.mjs","browser":{"./dist/liquid.node.js":"./dist/liquid.browser.umd.js","./dist/liquid.node.mjs":"./dist/liquid.browser.mjs"},"types":"dist/index.d.ts","engines":{"node":">=16"},"scripts":{"lint":"eslint \"**/*.mjs\" \"**/*.ts\" .","check":"npm run build && npm run build:docs && npm test && npm run lint && npm run perf:diff","test":"jest","test:coverage":"jest --coverage src test/integration","test:e2e":"jest test/e2e","test:demo":"./test/demo/test.sh","perf:diff":"bin/perf-diff.sh","perf:engines":"cd benchmark && npm run engines","version":"npm run build && npm test","build":"rollup -c rollup.config.mjs","build:cjs":"BUNDLES=cjs rollup -c rollup.config.mjs","build:min":"BUNDLES=min rollup -c rollup.config.mjs","build:umd":"BUNDLES=umd rollup -c rollup.config.mjs","build:charmap":"./bin/character-gen.js > src/util/character.ts","build:docs":"bin/build-docs.sh"},"bin":{"liquidjs":"./bin/liquid.js","liquid":"./bin/liquid.js"},"repository":{"type":"git","url":"git+https://github.com/harttle/liquidjs.git"},"funding":{"type":"opencollective","url":"https://opencollective.com/liquidjs"},"files":["bin/liquid.js","dist","LICENSE","README.md"],"keywords":["liquid","template engine","express","jinja","shopify"],"author":"Harttle","license":"MIT","bugs":{"url":"https://github.com/harttle/liquidjs/issues"},"homepage":"https://github.com/harttle/liquidjs#readme","devDependencies":{"@commitlint/cli":"^12.1.4","@commitlint/config-conventional":"^8.2.0","@semantic-release/changelog":"^6.0.2","@semantic-release/commit-analyzer":"^9.0.2","@semantic-release/git":"^10.0.1","@semantic-release/npm":"^9.0.2","@semantic-release/release-notes-generator":"^10.0.3","@types/benchmark":"^1.0.31","@types/express":"^4.17.2","@types/jest":"^29.4.0","@types/jsdom":"^12.2.2","@types/node":"^22.3.0","@types/sinon":"^10.0.13","@types/supertest":"^2.0.7","@typescript-eslint/eslint-plugin":"^5.6.0","@typescript-eslint/parser":"^5.6.0","all-contributors-cli":"^6.24.0","benchmark":"^2.1.4","coveralls":"^3.0.2","cross-env":"^5.2.0","eslint":"^7.32.0","eslint-config-standard":"^12.0.0","eslint-plugin-deprecation":"^1.3.2","eslint-plugin-import":"^2.27.5","eslint-plugin-mocha":"^5.3.0","eslint-plugin-node":"^8.0.1","eslint-plugin-promise":"^4.0.1","eslint-plugin-standard":"^4.0.0","express":"^4.16.4","husky":"^4.2.5","jest":"^29.5.0","jsdom":"^16.5.0","rollup":"^1.26.3","rollup-plugin-replace":"^2.1.0","rollup-plugin-typescript2":"^0.31.1","rollup-plugin-uglify":"^6.0.4","rollup-plugin-version-injector":"^1.3.3","semantic-release":"^19.0.3","sinon":"^15.0.2","supertest":"^3.4.2","ts-jest":"^29.0.5","tslib":"^2.3.1","typedoc":"^0.26.5","typedoc-plugin-missing-exports":"^3.0.0","typescript":"^4.5.3"},"dependencies":{"commander":"^10.0.0"},"release":{"branch":"master","plugins":["@semantic-release/commit-analyzer","@semantic-release/release-notes-generator","@semantic-release/changelog","@semantic-release/npm",["@semantic-release/git",{"assets":["package.json","package-lock.json","CHANGELOG.md"],"message":"chore(release): ${nextRelease.version} [skip ci]\n\n${nextRelease.notes}"}],["@semantic-release/github",{"assets":[{"path":"dist/*.umd.js","label":"liquid.js"},{"path":"dist/*.min.js","label":"liquid.min.js"},{"path":"dist/*.min.js.map","label":"liquid.min.js.map"}]}]]},"nyc":{"extension":[".ts"]},"husky":{"hooks":{"pre-commit":"npm run check","commit-msg":"commitlint -E HUSKY_GIT_PARAMS"}},"_lastModified":"2026-11-
|
|
1
|
+
{"name":"liquidjs","version":"10.23.0","sideEffects":false,"description":"A simple, expressive and safe Shopify / Github Pages compatible template engine in pure JavaScript.","main":"dist/liquid.node.js","module":"dist/liquid.node.mjs","es2015":"dist/liquid.browser.mjs","browser":{"./dist/liquid.node.js":"./dist/liquid.browser.umd.js","./dist/liquid.node.mjs":"./dist/liquid.browser.mjs"},"types":"dist/index.d.ts","engines":{"node":">=16"},"scripts":{"lint":"eslint \"**/*.mjs\" \"**/*.ts\" .","check":"npm run build && npm run build:docs && npm test && npm run lint && npm run perf:diff","test":"jest","test:coverage":"jest --coverage src test/integration","test:e2e":"jest test/e2e","test:demo":"./test/demo/test.sh","perf:diff":"bin/perf-diff.sh","perf:engines":"cd benchmark && npm run engines","version":"npm run build && npm test","build":"rollup -c rollup.config.mjs","build:cjs":"BUNDLES=cjs rollup -c rollup.config.mjs","build:min":"BUNDLES=min rollup -c rollup.config.mjs","build:umd":"BUNDLES=umd rollup -c rollup.config.mjs","build:charmap":"./bin/character-gen.js > src/util/character.ts","build:docs":"bin/build-docs.sh"},"bin":{"liquidjs":"./bin/liquid.js","liquid":"./bin/liquid.js"},"repository":{"type":"git","url":"git+https://github.com/harttle/liquidjs.git"},"funding":{"type":"opencollective","url":"https://opencollective.com/liquidjs"},"files":["bin/liquid.js","dist","LICENSE","README.md"],"keywords":["liquid","template engine","express","jinja","shopify"],"author":"Harttle","license":"MIT","bugs":{"url":"https://github.com/harttle/liquidjs/issues"},"homepage":"https://github.com/harttle/liquidjs#readme","devDependencies":{"@commitlint/cli":"^12.1.4","@commitlint/config-conventional":"^8.2.0","@semantic-release/changelog":"^6.0.2","@semantic-release/commit-analyzer":"^9.0.2","@semantic-release/git":"^10.0.1","@semantic-release/npm":"^9.0.2","@semantic-release/release-notes-generator":"^10.0.3","@types/benchmark":"^1.0.31","@types/express":"^4.17.2","@types/jest":"^29.4.0","@types/jsdom":"^12.2.2","@types/node":"^22.3.0","@types/sinon":"^10.0.13","@types/supertest":"^2.0.7","@typescript-eslint/eslint-plugin":"^5.6.0","@typescript-eslint/parser":"^5.6.0","all-contributors-cli":"^6.24.0","benchmark":"^2.1.4","coveralls":"^3.0.2","cross-env":"^5.2.0","eslint":"^7.32.0","eslint-config-standard":"^12.0.0","eslint-plugin-deprecation":"^1.3.2","eslint-plugin-import":"^2.27.5","eslint-plugin-mocha":"^5.3.0","eslint-plugin-node":"^8.0.1","eslint-plugin-promise":"^4.0.1","eslint-plugin-standard":"^4.0.0","express":"^4.16.4","husky":"^4.2.5","jest":"^29.5.0","jsdom":"^16.5.0","rollup":"^1.26.3","rollup-plugin-replace":"^2.1.0","rollup-plugin-typescript2":"^0.31.1","rollup-plugin-uglify":"^6.0.4","rollup-plugin-version-injector":"^1.3.3","semantic-release":"^19.0.3","sinon":"^15.0.2","supertest":"^3.4.2","ts-jest":"^29.0.5","tslib":"^2.3.1","typedoc":"^0.26.5","typedoc-plugin-missing-exports":"^3.0.0","typescript":"^4.5.3"},"dependencies":{"commander":"^10.0.0"},"release":{"branch":"master","plugins":["@semantic-release/commit-analyzer","@semantic-release/release-notes-generator","@semantic-release/changelog","@semantic-release/npm",["@semantic-release/git",{"assets":["package.json","package-lock.json","CHANGELOG.md"],"message":"chore(release): ${nextRelease.version} [skip ci]\n\n${nextRelease.notes}"}],["@semantic-release/github",{"assets":[{"path":"dist/*.umd.js","label":"liquid.js"},{"path":"dist/*.min.js","label":"liquid.min.js"},{"path":"dist/*.min.js.map","label":"liquid.min.js.map"}]}]]},"nyc":{"extension":[".ts"]},"husky":{"hooks":{"pre-commit":"npm run check","commit-msg":"commitlint -E HUSKY_GIT_PARAMS"}},"_lastModified":"2026-11-24T11:21:08.662Z"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"name":"ses","version":"1.14.0","description":"Hardened JavaScript for Fearless Cooperation","keywords":["lockdown","harden","Compartment","assert","security","confinement","isolation","object capabilities","ocaps","secure execution","third-party code","prototype pollution","supply-chain attack","plugin"],"author":"Agoric","license":"Apache-2.0","homepage":"https://github.com/Agoric/SES-shim/tree/master/packages/ses#readme","repository":{"type":"git","url":"git+https://github.com/endojs/endo.git","directory":"packages/ses"},"bugs":{"url":"https://github.com/endojs/endo/issues"},"type":"module","main":"./dist/ses.cjs","module":"./index.js","unpkg":"./dist/ses.umd.js","types":"./types.d.ts","exports":{".":{"import":{"types":"./types.d.ts","xs":"./src-xs/index.js","default":"./index.js"},"require":{"types":"./dist/types.d.cts","default":"./dist/ses.cjs"}},"./lockdown":{"import":{"types":"./types.d.ts","default":"./index.js"},"require":{"types":"./dist/types.d.cts","default":"./dist/ses.cjs"}},"./hermes":{"require":{"types":"./dist/types.d.cts","default":"./dist/ses-hermes.cjs"}},"./tools.js":"./tools.js","./assert-shim.js":"./assert-shim.js","./lockdown-shim.js":{"xs":"./src-xs/lockdown-shim.js","default":"./lockdown-shim.js"},"./compartment-shim.js":{"xs":"./src-xs/compartment-shim.js","default":"./compartment-shim.js"},"./console-shim.js":"./console-shim.js","./package.json":"./package.json"},"scripts":{"build:vanilla":"node scripts/bundle.js","build:hermes":"node scripts/bundle.js hermes","build":"yarn build:vanilla && yarn build:hermes","clean":"rm -rf dist","cover":"c8 ava","demo":"python3 -m http.server","lint":"yarn lint:types && yarn lint:eslint","lint-fix":"eslint --fix .","lint:eslint":"eslint .","lint:types":"tsc","prepare":"npm run clean && npm run build","qt":"ava","test":"tsd && ava","test:hermes":"./scripts/hermes-test.sh","test:xs":"xst dist/ses.umd.js test/_lockdown-safe.js && node scripts/generate-test-xs.js && xst tmp/test-xs.js && rm -rf tmp","postpack":"git clean -fX \"*.d.ts*\" \"*.d.cts*\" \"*.d.mts*\" \"*.tsbuildinfo\""},"dependencies":{"@endo/cache-map":"^1.1.0","@endo/env-options":"^1.1.11","@endo/immutable-arraybuffer":"^1.1.2"},"devDependencies":{"@babel/generator":"^7.26.3","@babel/parser":"~7.26.2","@babel/traverse":"~7.25.9","@babel/types":"~7.26.0","@endo/compartment-mapper":"^1.6.3","@endo/module-source":"^1.3.3","@endo/test262-runner":"^0.1.48","@types/babel__traverse":"^7.20.5","ava":"^6.1.3","babel-eslint":"^10.1.0","c8":"^7.14.0","core-js":"^3.31.0","eslint":"^8.57.1","eslint-config-airbnb-base":"^15.0.0","eslint-config-prettier":"^9.1.0","eslint-plugin-eslint-comments":"^3.2.0","eslint-plugin-import":"^2.31.0","hermes-engine-cli":"^0.12.0","prettier":"^3.5.3","terser":"^5.16.6","tsd":"^0.31.2","typescript":"~5.8.3"},"files":["./*.d.ts","./*.js","./*.map","LICENSE*","SECURITY*","dist","lib","src","tools"],"publishConfig":{"access":"public"},"eslintConfig":{"extends":["plugin:@endo/ses"]},"ava":{"files":["test/**/*.test.*"],"timeout":"2m"},"typeCoverage":{"atLeast":81.17},"gitHead":"9815aea9541f241389d2135c6097a7442bdffa17","_lastModified":"2026-11-
|
|
1
|
+
{"name":"ses","version":"1.14.0","description":"Hardened JavaScript for Fearless Cooperation","keywords":["lockdown","harden","Compartment","assert","security","confinement","isolation","object capabilities","ocaps","secure execution","third-party code","prototype pollution","supply-chain attack","plugin"],"author":"Agoric","license":"Apache-2.0","homepage":"https://github.com/Agoric/SES-shim/tree/master/packages/ses#readme","repository":{"type":"git","url":"git+https://github.com/endojs/endo.git","directory":"packages/ses"},"bugs":{"url":"https://github.com/endojs/endo/issues"},"type":"module","main":"./dist/ses.cjs","module":"./index.js","unpkg":"./dist/ses.umd.js","types":"./types.d.ts","exports":{".":{"import":{"types":"./types.d.ts","xs":"./src-xs/index.js","default":"./index.js"},"require":{"types":"./dist/types.d.cts","default":"./dist/ses.cjs"}},"./lockdown":{"import":{"types":"./types.d.ts","default":"./index.js"},"require":{"types":"./dist/types.d.cts","default":"./dist/ses.cjs"}},"./hermes":{"require":{"types":"./dist/types.d.cts","default":"./dist/ses-hermes.cjs"}},"./tools.js":"./tools.js","./assert-shim.js":"./assert-shim.js","./lockdown-shim.js":{"xs":"./src-xs/lockdown-shim.js","default":"./lockdown-shim.js"},"./compartment-shim.js":{"xs":"./src-xs/compartment-shim.js","default":"./compartment-shim.js"},"./console-shim.js":"./console-shim.js","./package.json":"./package.json"},"scripts":{"build:vanilla":"node scripts/bundle.js","build:hermes":"node scripts/bundle.js hermes","build":"yarn build:vanilla && yarn build:hermes","clean":"rm -rf dist","cover":"c8 ava","demo":"python3 -m http.server","lint":"yarn lint:types && yarn lint:eslint","lint-fix":"eslint --fix .","lint:eslint":"eslint .","lint:types":"tsc","prepare":"npm run clean && npm run build","qt":"ava","test":"tsd && ava","test:hermes":"./scripts/hermes-test.sh","test:xs":"xst dist/ses.umd.js test/_lockdown-safe.js && node scripts/generate-test-xs.js && xst tmp/test-xs.js && rm -rf tmp","postpack":"git clean -fX \"*.d.ts*\" \"*.d.cts*\" \"*.d.mts*\" \"*.tsbuildinfo\""},"dependencies":{"@endo/cache-map":"^1.1.0","@endo/env-options":"^1.1.11","@endo/immutable-arraybuffer":"^1.1.2"},"devDependencies":{"@babel/generator":"^7.26.3","@babel/parser":"~7.26.2","@babel/traverse":"~7.25.9","@babel/types":"~7.26.0","@endo/compartment-mapper":"^1.6.3","@endo/module-source":"^1.3.3","@endo/test262-runner":"^0.1.48","@types/babel__traverse":"^7.20.5","ava":"^6.1.3","babel-eslint":"^10.1.0","c8":"^7.14.0","core-js":"^3.31.0","eslint":"^8.57.1","eslint-config-airbnb-base":"^15.0.0","eslint-config-prettier":"^9.1.0","eslint-plugin-eslint-comments":"^3.2.0","eslint-plugin-import":"^2.31.0","hermes-engine-cli":"^0.12.0","prettier":"^3.5.3","terser":"^5.16.6","tsd":"^0.31.2","typescript":"~5.8.3"},"files":["./*.d.ts","./*.js","./*.map","LICENSE*","SECURITY*","dist","lib","src","tools"],"publishConfig":{"access":"public"},"eslintConfig":{"extends":["plugin:@endo/ses"]},"ava":{"files":["test/**/*.test.*"],"timeout":"2m"},"typeCoverage":{"atLeast":81.17},"gitHead":"9815aea9541f241389d2135c6097a7442bdffa17","_lastModified":"2026-11-24T11:21:07.740Z"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"name":"zod","version":"4.3.5","type":"module","license":"MIT","author":"Colin McDonnell <zod@colinhacks.com>","description":"TypeScript-first schema declaration and validation library with static type inference","homepage":"https://zod.dev","llms":"https://zod.dev/llms.txt","llmsFull":"https://zod.dev/llms-full.txt","mcpServer":"https://mcp.inkeep.com/zod/mcp","funding":"https://github.com/sponsors/colinhacks","sideEffects":false,"files":["src","**/*.js","**/*.mjs","**/*.cjs","**/*.d.ts","**/*.d.mts","**/*.d.cts","**/package.json"],"keywords":["typescript","schema","validation","type","inference"],"main":"./index.cjs","types":"./index.d.cts","module":"./index.js","zshy":{"exports":{"./package.json":"./package.json",".":"./src/index.ts","./mini":"./src/mini/index.ts","./locales":"./src/locales/index.ts","./v3":"./src/v3/index.ts","./v4":"./src/v4/index.ts","./v4-mini":"./src/v4-mini/index.ts","./v4/mini":"./src/v4/mini/index.ts","./v4/core":"./src/v4/core/index.ts","./v4/locales":"./src/v4/locales/index.ts","./v4/locales/*":"./src/v4/locales/*"},"conditions":{"@zod/source":"src"}},"exports":{"./package.json":"./package.json",".":{"@zod/source":"./src/index.ts","types":"./index.d.cts","import":"./index.js","require":"./index.cjs"},"./mini":{"@zod/source":"./src/mini/index.ts","types":"./mini/index.d.cts","import":"./mini/index.js","require":"./mini/index.cjs"},"./locales":{"@zod/source":"./src/locales/index.ts","types":"./locales/index.d.cts","import":"./locales/index.js","require":"./locales/index.cjs"},"./v3":{"@zod/source":"./src/v3/index.ts","types":"./v3/index.d.cts","import":"./v3/index.js","require":"./v3/index.cjs"},"./v4":{"@zod/source":"./src/v4/index.ts","types":"./v4/index.d.cts","import":"./v4/index.js","require":"./v4/index.cjs"},"./v4-mini":{"@zod/source":"./src/v4-mini/index.ts","types":"./v4-mini/index.d.cts","import":"./v4-mini/index.js","require":"./v4-mini/index.cjs"},"./v4/mini":{"@zod/source":"./src/v4/mini/index.ts","types":"./v4/mini/index.d.cts","import":"./v4/mini/index.js","require":"./v4/mini/index.cjs"},"./v4/core":{"@zod/source":"./src/v4/core/index.ts","types":"./v4/core/index.d.cts","import":"./v4/core/index.js","require":"./v4/core/index.cjs"},"./v4/locales":{"@zod/source":"./src/v4/locales/index.ts","types":"./v4/locales/index.d.cts","import":"./v4/locales/index.js","require":"./v4/locales/index.cjs"},"./v4/locales/*":{"@zod/source":"./src/v4/locales/*","types":"./v4/locales/*","import":"./v4/locales/*","require":"./v4/locales/*"}},"repository":{"type":"git","url":"git+https://github.com/colinhacks/zod.git"},"bugs":{"url":"https://github.com/colinhacks/zod/issues"},"support":{"backing":{"npm-funding":true}},"scripts":{"clean":"git clean -xdf . -e node_modules","build":"zshy --project tsconfig.build.json","postbuild":"tsx ../../scripts/write-stub-package-jsons.ts && pnpm biome check --write .","test:watch":"pnpm vitest","test":"pnpm vitest run","prepublishOnly":"tsx ../../scripts/check-versions.ts"},"_lastModified":"2026-11-
|
|
1
|
+
{"name":"zod","version":"4.3.5","type":"module","license":"MIT","author":"Colin McDonnell <zod@colinhacks.com>","description":"TypeScript-first schema declaration and validation library with static type inference","homepage":"https://zod.dev","llms":"https://zod.dev/llms.txt","llmsFull":"https://zod.dev/llms-full.txt","mcpServer":"https://mcp.inkeep.com/zod/mcp","funding":"https://github.com/sponsors/colinhacks","sideEffects":false,"files":["src","**/*.js","**/*.mjs","**/*.cjs","**/*.d.ts","**/*.d.mts","**/*.d.cts","**/package.json"],"keywords":["typescript","schema","validation","type","inference"],"main":"./index.cjs","types":"./index.d.cts","module":"./index.js","zshy":{"exports":{"./package.json":"./package.json",".":"./src/index.ts","./mini":"./src/mini/index.ts","./locales":"./src/locales/index.ts","./v3":"./src/v3/index.ts","./v4":"./src/v4/index.ts","./v4-mini":"./src/v4-mini/index.ts","./v4/mini":"./src/v4/mini/index.ts","./v4/core":"./src/v4/core/index.ts","./v4/locales":"./src/v4/locales/index.ts","./v4/locales/*":"./src/v4/locales/*"},"conditions":{"@zod/source":"src"}},"exports":{"./package.json":"./package.json",".":{"@zod/source":"./src/index.ts","types":"./index.d.cts","import":"./index.js","require":"./index.cjs"},"./mini":{"@zod/source":"./src/mini/index.ts","types":"./mini/index.d.cts","import":"./mini/index.js","require":"./mini/index.cjs"},"./locales":{"@zod/source":"./src/locales/index.ts","types":"./locales/index.d.cts","import":"./locales/index.js","require":"./locales/index.cjs"},"./v3":{"@zod/source":"./src/v3/index.ts","types":"./v3/index.d.cts","import":"./v3/index.js","require":"./v3/index.cjs"},"./v4":{"@zod/source":"./src/v4/index.ts","types":"./v4/index.d.cts","import":"./v4/index.js","require":"./v4/index.cjs"},"./v4-mini":{"@zod/source":"./src/v4-mini/index.ts","types":"./v4-mini/index.d.cts","import":"./v4-mini/index.js","require":"./v4-mini/index.cjs"},"./v4/mini":{"@zod/source":"./src/v4/mini/index.ts","types":"./v4/mini/index.d.cts","import":"./v4/mini/index.js","require":"./v4/mini/index.cjs"},"./v4/core":{"@zod/source":"./src/v4/core/index.ts","types":"./v4/core/index.d.cts","import":"./v4/core/index.js","require":"./v4/core/index.cjs"},"./v4/locales":{"@zod/source":"./src/v4/locales/index.ts","types":"./v4/locales/index.d.cts","import":"./v4/locales/index.js","require":"./v4/locales/index.cjs"},"./v4/locales/*":{"@zod/source":"./src/v4/locales/*","types":"./v4/locales/*","import":"./v4/locales/*","require":"./v4/locales/*"}},"repository":{"type":"git","url":"git+https://github.com/colinhacks/zod.git"},"bugs":{"url":"https://github.com/colinhacks/zod/issues"},"support":{"backing":{"npm-funding":true}},"scripts":{"clean":"git clean -xdf . -e node_modules","build":"zshy --project tsconfig.build.json","postbuild":"tsx ../../scripts/write-stub-package-jsons.ts && pnpm biome check --write .","test:watch":"pnpm vitest","test":"pnpm vitest run","prepublishOnly":"tsx ../../scripts/check-versions.ts"},"_lastModified":"2026-11-24T11:21:10.634Z"}
|
|
@@ -137,6 +137,12 @@ export declare class FlowModelRepository extends Repository {
|
|
|
137
137
|
static nodesToModel(nodes: any[], rootUid: string): any;
|
|
138
138
|
insertModel(model: any, options?: Transactionable): Promise<any>;
|
|
139
139
|
updateSingleNode(node: SchemaNode, options?: Transactionable): Promise<boolean>;
|
|
140
|
+
ensureRouteContent({ uid: preferredUid, parentId, subKey, use, }: {
|
|
141
|
+
uid?: string;
|
|
142
|
+
parentId: string;
|
|
143
|
+
subKey: 'page' | 'grid';
|
|
144
|
+
use: string;
|
|
145
|
+
}, options?: Transactionable): Promise<string>;
|
|
140
146
|
upsertModel(model: any, options?: Transactionable): Promise<string>;
|
|
141
147
|
findModelById(uid: string, options?: GetJsonSchemaOptions): Promise<any>;
|
|
142
148
|
findModelNodeSnapshotById(uid: string, options?: Transactionable): Promise<FlowModelNodeSnapshot | null>;
|
|
@@ -1387,6 +1387,19 @@ WHERE TreeTable.depth = 1 AND TreeTable.ancestor = :ancestor and TreeTable.sort
|
|
|
1387
1387
|
}
|
|
1388
1388
|
return false;
|
|
1389
1389
|
}
|
|
1390
|
+
async ensureRouteContent({
|
|
1391
|
+
uid: preferredUid,
|
|
1392
|
+
parentId,
|
|
1393
|
+
subKey,
|
|
1394
|
+
use
|
|
1395
|
+
}, options) {
|
|
1396
|
+
const parent = await this.model.findByPk(parentId, { transaction: options == null ? void 0 : options.transaction, lock: true });
|
|
1397
|
+
if (!parent) throw new Error("Route content parent does not exist");
|
|
1398
|
+
const existing = await this.findModelUidByParentId(parentId, { ...options, subKey });
|
|
1399
|
+
if (existing) return existing;
|
|
1400
|
+
const availableUid = preferredUid && !await this.model.findByPk(preferredUid, options) ? preferredUid : void 0;
|
|
1401
|
+
return this.upsertModel({ uid: availableUid, parentId, subKey, use, subType: "object", async: true }, options);
|
|
1402
|
+
}
|
|
1390
1403
|
async upsertModel(model, options) {
|
|
1391
1404
|
let childOptions = null;
|
|
1392
1405
|
if (model.parentId) {
|
|
@@ -1733,6 +1746,9 @@ __decorateClass([
|
|
|
1733
1746
|
__decorateClass([
|
|
1734
1747
|
transaction()
|
|
1735
1748
|
], _FlowModelRepository.prototype, "updateSingleNode", 1);
|
|
1749
|
+
__decorateClass([
|
|
1750
|
+
transaction()
|
|
1751
|
+
], _FlowModelRepository.prototype, "ensureRouteContent", 1);
|
|
1736
1752
|
__decorateClass([
|
|
1737
1753
|
transaction()
|
|
1738
1754
|
], _FlowModelRepository.prototype, "upsertModel", 1);
|
package/dist/server/server.js
CHANGED
|
@@ -160,6 +160,15 @@ class PluginUISchemaStorageServer extends import_server.Plugin {
|
|
|
160
160
|
save: async (ctx, next) => {
|
|
161
161
|
const { values } = ctx.action.params;
|
|
162
162
|
const repository = ctx.db.getRepository("flowModels");
|
|
163
|
+
if (String(ctx.action.params.ensureRouteContent) === "true") {
|
|
164
|
+
ctx.assert(
|
|
165
|
+
typeof (values == null ? void 0 : values.parentId) === "string" && values.parentId && typeof values.use === "string" && ["page", "grid"].includes(values.subKey) && values.subType === "object",
|
|
166
|
+
400,
|
|
167
|
+
"Expected a page or grid object slot"
|
|
168
|
+
);
|
|
169
|
+
ctx.body = await repository.ensureRouteContent(values);
|
|
170
|
+
return next();
|
|
171
|
+
}
|
|
163
172
|
const uid2 = await repository.upsertModel(values);
|
|
164
173
|
ctx.body = uid2;
|
|
165
174
|
await next();
|
package/package.json
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"displayName.zh-CN": "前端流引擎",
|
|
5
5
|
"description": "",
|
|
6
6
|
"description.zh-CN": "",
|
|
7
|
-
"version": "2.4.0-alpha.
|
|
7
|
+
"version": "2.4.0-alpha.19",
|
|
8
8
|
"main": "./dist/server/index.js",
|
|
9
9
|
"license": "Apache-2.0",
|
|
10
10
|
"devDependencies": {
|
|
@@ -27,5 +27,5 @@
|
|
|
27
27
|
"@nocobase/test": "2.x",
|
|
28
28
|
"@nocobase/utils": "2.x"
|
|
29
29
|
},
|
|
30
|
-
"gitHead": "
|
|
30
|
+
"gitHead": "b958d8e10e75dd27b0e7a2882ffc8f9bda9da0d8"
|
|
31
31
|
}
|