@nocobase/plugin-ui-schema-storage 1.2.13-alpha → 1.3.0-alpha.20240710084543
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/package.json +2 -2
- package/dist/client/index.d.ts +0 -13
- package/dist/client/index.js +0 -10
- package/dist/externalVersion.js +0 -20
- package/dist/index.d.ts +0 -11
- package/dist/index.js +0 -39
- package/dist/server/actions/ui-schema-action.d.ts +0 -27
- package/dist/server/actions/ui-schema-action.js +0 -140
- package/dist/server/collections/uiSchemaServerHooks.d.ts +0 -11
- package/dist/server/collections/uiSchemaServerHooks.js +0 -58
- package/dist/server/collections/uiSchemaTemplates.d.ts +0 -10
- package/dist/server/collections/uiSchemaTemplates.js +0 -75
- package/dist/server/collections/uiSchemaTreePath.d.ts +0 -11
- package/dist/server/collections/uiSchemaTreePath.js +0 -73
- package/dist/server/collections/uiSchemas.d.ts +0 -11
- package/dist/server/collections/uiSchemas.js +0 -62
- package/dist/server/dao/ui_schema_node_dao.d.ts +0 -26
- package/dist/server/dao/ui_schema_node_dao.js +0 -24
- package/dist/server/helper.d.ts +0 -8
- package/dist/server/helper.js +0 -9
- package/dist/server/index.d.ts +0 -12
- package/dist/server/index.js +0 -41
- package/dist/server/migrations/20230330214649-filter-form-block.d.ts +0 -13
- package/dist/server/migrations/20230330214649-filter-form-block.js +0 -58
- package/dist/server/migrations/20230509221649-association-select.d.ts +0 -13
- package/dist/server/migrations/20230509221649-association-select.js +0 -71
- package/dist/server/migrations/20230509235247-record-picker.d.ts +0 -16
- package/dist/server/migrations/20230509235247-record-picker.js +0 -121
- package/dist/server/migrations/20230510235247-form-field.d.ts +0 -13
- package/dist/server/migrations/20230510235247-form-field.js +0 -100
- package/dist/server/migrations/20230522231231-association-field.d.ts +0 -13
- package/dist/server/migrations/20230522231231-association-field.js +0 -74
- package/dist/server/migrations/20231015125000-support-filter-blocks-in-select-record-drawer.d.ts +0 -13
- package/dist/server/migrations/20231015125000-support-filter-blocks-in-select-record-drawer.js +0 -55
- package/dist/server/model.d.ts +0 -14
- package/dist/server/model.js +0 -42
- package/dist/server/repository.d.ts +0 -101
- package/dist/server/repository.js +0 -980
- package/dist/server/server-hooks/hooks/bind-menu-to-role.d.ts +0 -13
- package/dist/server/server-hooks/hooks/bind-menu-to-role.js +0 -49
- package/dist/server/server-hooks/hooks/factory.d.ts +0 -14
- package/dist/server/server-hooks/hooks/factory.js +0 -42
- package/dist/server/server-hooks/hooks/index.d.ts +0 -14
- package/dist/server/server-hooks/hooks/index.js +0 -45
- package/dist/server/server-hooks/hooks/remove-parents-if-no-children.d.ts +0 -14
- package/dist/server/server-hooks/hooks/remove-parents-if-no-children.js +0 -44
- package/dist/server/server-hooks/hooks/remove-schema.d.ts +0 -14
- package/dist/server/server-hooks/hooks/remove-schema.js +0 -51
- package/dist/server/server-hooks/index.d.ts +0 -33
- package/dist/server/server-hooks/index.js +0 -174
- package/dist/server/server-hooks/model.d.ts +0 -11
- package/dist/server/server-hooks/model.js +0 -38
- package/dist/server/server.d.ts +0 -17
- package/dist/server/server.js +0 -117
- package/dist/swagger/index.d.ts +0 -334
- package/dist/swagger/index.js +0 -363
package/package.json
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"displayName.zh-CN": "UI schema 存储服务",
|
|
5
5
|
"description": "Provides centralized UI schema storage service.",
|
|
6
6
|
"description.zh-CN": "提供中心化的 UI schema 存储服务。",
|
|
7
|
-
"version": "1.
|
|
7
|
+
"version": "1.3.0-alpha.20240710084543",
|
|
8
8
|
"license": "AGPL-3.0",
|
|
9
9
|
"main": "./dist/server/index.js",
|
|
10
10
|
"homepage": "https://docs.nocobase.com/handbook/ui-schema-storage",
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
"@nocobase/test": "1.x",
|
|
25
25
|
"@nocobase/utils": "1.x"
|
|
26
26
|
},
|
|
27
|
-
"gitHead": "
|
|
27
|
+
"gitHead": "07a8b596fc64a9779a194cb9b0dc2ca7570ed9d4",
|
|
28
28
|
"keywords": [
|
|
29
29
|
"System & security"
|
|
30
30
|
]
|
package/dist/client/index.d.ts
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
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 { Plugin } from '@nocobase/client';
|
|
10
|
-
declare class PluginUISchemaStorageClient extends Plugin {
|
|
11
|
-
load(): Promise<void>;
|
|
12
|
-
}
|
|
13
|
-
export default PluginUISchemaStorageClient;
|
package/dist/client/index.js
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
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
|
-
|
|
10
|
-
(function(e,n){typeof exports=="object"&&typeof module!="undefined"?n(exports,require("@nocobase/client")):typeof define=="function"&&define.amd?define(["exports","@nocobase/client"],n):(e=typeof globalThis!="undefined"?globalThis:e||self,n(e["@nocobase/plugin-ui-schema-storage"]={},e["@nocobase/client"]))})(this,function(e,n){"use strict";var d=(e,n,o)=>new Promise((u,c)=>{var l=i=>{try{t(o.next(i))}catch(s){c(s)}},a=i=>{try{t(o.throw(i))}catch(s){c(s)}},t=i=>i.done?u(i.value):Promise.resolve(i.value).then(l,a);t((o=o.apply(e,n)).next())});class o extends n.Plugin{load(){return d(this,null,function*(){})}}e.default=o,Object.defineProperties(e,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|
package/dist/externalVersion.js
DELETED
|
@@ -1,20 +0,0 @@
|
|
|
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
|
-
|
|
10
|
-
module.exports = {
|
|
11
|
-
"@nocobase/client": "1.2.13-alpha",
|
|
12
|
-
"@nocobase/database": "1.2.13-alpha",
|
|
13
|
-
"@nocobase/cache": "1.2.13-alpha",
|
|
14
|
-
"@nocobase/utils": "1.2.13-alpha",
|
|
15
|
-
"lodash": "4.17.21",
|
|
16
|
-
"@nocobase/server": "1.2.13-alpha",
|
|
17
|
-
"@nocobase/actions": "1.2.13-alpha",
|
|
18
|
-
"@nocobase/resourcer": "1.2.13-alpha",
|
|
19
|
-
"@formily/json-schema": "2.3.0"
|
|
20
|
-
};
|
package/dist/index.d.ts
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
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
|
-
export * from './server';
|
|
10
|
-
import { PluginUISchemaStorageServer } from './server';
|
|
11
|
-
export default PluginUISchemaStorageServer;
|
package/dist/index.js
DELETED
|
@@ -1,39 +0,0 @@
|
|
|
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
|
-
|
|
10
|
-
var __defProp = Object.defineProperty;
|
|
11
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
12
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
13
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
14
|
-
var __export = (target, all) => {
|
|
15
|
-
for (var name in all)
|
|
16
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
17
|
-
};
|
|
18
|
-
var __copyProps = (to, from, except, desc) => {
|
|
19
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
20
|
-
for (let key of __getOwnPropNames(from))
|
|
21
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
22
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
23
|
-
}
|
|
24
|
-
return to;
|
|
25
|
-
};
|
|
26
|
-
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
|
27
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
28
|
-
var src_exports = {};
|
|
29
|
-
__export(src_exports, {
|
|
30
|
-
default: () => src_default
|
|
31
|
-
});
|
|
32
|
-
module.exports = __toCommonJS(src_exports);
|
|
33
|
-
__reExport(src_exports, require("./server"), module.exports);
|
|
34
|
-
var import_server = require("./server");
|
|
35
|
-
var src_default = import_server.PluginUISchemaStorageServer;
|
|
36
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
37
|
-
0 && (module.exports = {
|
|
38
|
-
...require("./server")
|
|
39
|
-
});
|
|
@@ -1,27 +0,0 @@
|
|
|
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 { Context } from '@nocobase/actions';
|
|
10
|
-
export declare const uiSchemaActions: {
|
|
11
|
-
getJsonSchema: (ctx: any, next: any) => Promise<void>;
|
|
12
|
-
getProperties: (ctx: any, next: any) => Promise<void>;
|
|
13
|
-
getParentJsonSchema: (ctx: any, next: any) => Promise<void>;
|
|
14
|
-
getParentProperty: (ctx: any, next: any) => Promise<void>;
|
|
15
|
-
insert: (ctx: any, next: any) => Promise<void>;
|
|
16
|
-
insertNewSchema: (ctx: any, next: any) => Promise<void>;
|
|
17
|
-
remove: (ctx: any, next: any) => Promise<void>;
|
|
18
|
-
patch: (ctx: any, next: any) => Promise<void>;
|
|
19
|
-
batchPatch: (ctx: any, next: any) => Promise<void>;
|
|
20
|
-
clearAncestor: (ctx: any, next: any) => Promise<void>;
|
|
21
|
-
insertAdjacent: (ctx: Context, next: any) => Promise<void>;
|
|
22
|
-
insertBeforeBegin: (ctx: Context, next: any) => Promise<void>;
|
|
23
|
-
insertAfterBegin: (ctx: Context, next: any) => Promise<void>;
|
|
24
|
-
insertBeforeEnd: (ctx: Context, next: any) => Promise<void>;
|
|
25
|
-
insertAfterEnd: (ctx: Context, next: any) => Promise<void>;
|
|
26
|
-
saveAsTemplate(ctx: Context, next: any): Promise<void>;
|
|
27
|
-
};
|
|
@@ -1,140 +0,0 @@
|
|
|
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
|
-
|
|
10
|
-
var __create = Object.create;
|
|
11
|
-
var __defProp = Object.defineProperty;
|
|
12
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
13
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
14
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
15
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
16
|
-
var __export = (target, all) => {
|
|
17
|
-
for (var name in all)
|
|
18
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
19
|
-
};
|
|
20
|
-
var __copyProps = (to, from, except, desc) => {
|
|
21
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
22
|
-
for (let key of __getOwnPropNames(from))
|
|
23
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
24
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
25
|
-
}
|
|
26
|
-
return to;
|
|
27
|
-
};
|
|
28
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
29
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
30
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
31
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
32
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
33
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
34
|
-
mod
|
|
35
|
-
));
|
|
36
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
37
|
-
var ui_schema_action_exports = {};
|
|
38
|
-
__export(ui_schema_action_exports, {
|
|
39
|
-
uiSchemaActions: () => uiSchemaActions
|
|
40
|
-
});
|
|
41
|
-
module.exports = __toCommonJS(ui_schema_action_exports);
|
|
42
|
-
var import_lodash = __toESM(require("lodash"));
|
|
43
|
-
const getRepositoryFromCtx = (ctx) => {
|
|
44
|
-
const repo = ctx.db.getCollection("uiSchemas").repository;
|
|
45
|
-
repo.setCache(ctx.cache);
|
|
46
|
-
return repo;
|
|
47
|
-
};
|
|
48
|
-
const callRepositoryMethod = (method, paramsKey, optionsBuilder) => {
|
|
49
|
-
return async (ctx, next) => {
|
|
50
|
-
const params = import_lodash.default.get(ctx.action.params, paramsKey);
|
|
51
|
-
const options = optionsBuilder ? optionsBuilder(ctx.action.params) : {};
|
|
52
|
-
const repository = getRepositoryFromCtx(ctx);
|
|
53
|
-
const returnValue = await repository[method](params, options);
|
|
54
|
-
ctx.body = returnValue || {
|
|
55
|
-
result: "ok"
|
|
56
|
-
};
|
|
57
|
-
await next();
|
|
58
|
-
};
|
|
59
|
-
};
|
|
60
|
-
function parseInsertAdjacentValues(values) {
|
|
61
|
-
if (import_lodash.default.has(values, "schema")) {
|
|
62
|
-
return values;
|
|
63
|
-
}
|
|
64
|
-
return { schema: values, wrap: null };
|
|
65
|
-
}
|
|
66
|
-
const uiSchemaActions = {
|
|
67
|
-
getJsonSchema: callRepositoryMethod("getJsonSchema", "resourceIndex", (params) => {
|
|
68
|
-
const includeAsyncNode = params == null ? void 0 : params.includeAsyncNode;
|
|
69
|
-
return {
|
|
70
|
-
readFromCache: !includeAsyncNode,
|
|
71
|
-
includeAsyncNode
|
|
72
|
-
};
|
|
73
|
-
}),
|
|
74
|
-
getProperties: callRepositoryMethod(
|
|
75
|
-
"getProperties",
|
|
76
|
-
"resourceIndex",
|
|
77
|
-
() => ({
|
|
78
|
-
readFromCache: true
|
|
79
|
-
})
|
|
80
|
-
),
|
|
81
|
-
getParentJsonSchema: callRepositoryMethod("getParentJsonSchema", "resourceIndex"),
|
|
82
|
-
getParentProperty: callRepositoryMethod("getParentProperty", "resourceIndex"),
|
|
83
|
-
insert: callRepositoryMethod("insert", "values"),
|
|
84
|
-
insertNewSchema: callRepositoryMethod("insertNewSchema", "values"),
|
|
85
|
-
remove: callRepositoryMethod("remove", "resourceIndex"),
|
|
86
|
-
patch: callRepositoryMethod("patch", "values"),
|
|
87
|
-
batchPatch: callRepositoryMethod("batchPatch", "values"),
|
|
88
|
-
clearAncestor: callRepositoryMethod("clearAncestor", "resourceIndex"),
|
|
89
|
-
insertAdjacent: insertPositionActionBuilder(),
|
|
90
|
-
insertBeforeBegin: insertPositionActionBuilder("beforeBegin"),
|
|
91
|
-
insertAfterBegin: insertPositionActionBuilder("afterBegin"),
|
|
92
|
-
insertBeforeEnd: insertPositionActionBuilder("beforeEnd"),
|
|
93
|
-
insertAfterEnd: insertPositionActionBuilder("afterEnd"),
|
|
94
|
-
async saveAsTemplate(ctx, next) {
|
|
95
|
-
const { filterByTk, values } = ctx.action.params;
|
|
96
|
-
const db = ctx.db;
|
|
97
|
-
const transaction = await db.sequelize.transaction();
|
|
98
|
-
try {
|
|
99
|
-
await db.getRepository("uiSchemaTemplates").create({
|
|
100
|
-
values: {
|
|
101
|
-
...values,
|
|
102
|
-
uid: filterByTk
|
|
103
|
-
},
|
|
104
|
-
transaction
|
|
105
|
-
});
|
|
106
|
-
await getRepositoryFromCtx(ctx).clearAncestor(filterByTk, { transaction });
|
|
107
|
-
ctx.body = {
|
|
108
|
-
result: "ok"
|
|
109
|
-
};
|
|
110
|
-
await transaction.commit();
|
|
111
|
-
} catch (error) {
|
|
112
|
-
await transaction.rollback();
|
|
113
|
-
throw error;
|
|
114
|
-
}
|
|
115
|
-
await next();
|
|
116
|
-
}
|
|
117
|
-
};
|
|
118
|
-
function insertPositionActionBuilder(position = void 0) {
|
|
119
|
-
return async function(ctx, next) {
|
|
120
|
-
const {
|
|
121
|
-
resourceIndex,
|
|
122
|
-
values,
|
|
123
|
-
removeParentsIfNoChildren,
|
|
124
|
-
breakRemoveOn,
|
|
125
|
-
position: positionFromUser
|
|
126
|
-
} = ctx.action.params;
|
|
127
|
-
const repository = getRepositoryFromCtx(ctx);
|
|
128
|
-
const { schema, wrap } = parseInsertAdjacentValues(values);
|
|
129
|
-
ctx.body = await repository.insertAdjacent(position || positionFromUser, resourceIndex, schema, {
|
|
130
|
-
removeParentsIfNoChildren,
|
|
131
|
-
breakRemoveOn,
|
|
132
|
-
wrap
|
|
133
|
-
});
|
|
134
|
-
await next();
|
|
135
|
-
};
|
|
136
|
-
}
|
|
137
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
138
|
-
0 && (module.exports = {
|
|
139
|
-
uiSchemaActions
|
|
140
|
-
});
|
|
@@ -1,11 +0,0 @@
|
|
|
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 { CollectionOptions } from '@nocobase/database';
|
|
10
|
-
declare const _default: CollectionOptions;
|
|
11
|
-
export default _default;
|
|
@@ -1,58 +0,0 @@
|
|
|
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
|
-
|
|
10
|
-
var __defProp = Object.defineProperty;
|
|
11
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
12
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
13
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
14
|
-
var __export = (target, all) => {
|
|
15
|
-
for (var name in all)
|
|
16
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
17
|
-
};
|
|
18
|
-
var __copyProps = (to, from, except, desc) => {
|
|
19
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
20
|
-
for (let key of __getOwnPropNames(from))
|
|
21
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
22
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
23
|
-
}
|
|
24
|
-
return to;
|
|
25
|
-
};
|
|
26
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
27
|
-
var uiSchemaServerHooks_exports = {};
|
|
28
|
-
__export(uiSchemaServerHooks_exports, {
|
|
29
|
-
default: () => uiSchemaServerHooks_default
|
|
30
|
-
});
|
|
31
|
-
module.exports = __toCommonJS(uiSchemaServerHooks_exports);
|
|
32
|
-
var uiSchemaServerHooks_default = {
|
|
33
|
-
dumpRules: "required",
|
|
34
|
-
name: "uiSchemaServerHooks",
|
|
35
|
-
model: "ServerHookModel",
|
|
36
|
-
// autoGenId: false,
|
|
37
|
-
timestamps: false,
|
|
38
|
-
fields: [
|
|
39
|
-
{ type: "belongsTo", name: "uiSchema", target: "uiSchemas", foreignKey: "uid" },
|
|
40
|
-
{ type: "string", name: "type" },
|
|
41
|
-
{
|
|
42
|
-
type: "string",
|
|
43
|
-
name: "collection"
|
|
44
|
-
},
|
|
45
|
-
{
|
|
46
|
-
type: "string",
|
|
47
|
-
name: "field"
|
|
48
|
-
},
|
|
49
|
-
{
|
|
50
|
-
type: "string",
|
|
51
|
-
name: "method"
|
|
52
|
-
},
|
|
53
|
-
{
|
|
54
|
-
type: "json",
|
|
55
|
-
name: "params"
|
|
56
|
-
}
|
|
57
|
-
]
|
|
58
|
-
};
|
|
@@ -1,10 +0,0 @@
|
|
|
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
|
-
declare const _default: import("@nocobase/database").CollectionOptions;
|
|
10
|
-
export default _default;
|
|
@@ -1,75 +0,0 @@
|
|
|
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
|
-
|
|
10
|
-
var __defProp = Object.defineProperty;
|
|
11
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
12
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
13
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
14
|
-
var __export = (target, all) => {
|
|
15
|
-
for (var name in all)
|
|
16
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
17
|
-
};
|
|
18
|
-
var __copyProps = (to, from, except, desc) => {
|
|
19
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
20
|
-
for (let key of __getOwnPropNames(from))
|
|
21
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
22
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
23
|
-
}
|
|
24
|
-
return to;
|
|
25
|
-
};
|
|
26
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
27
|
-
var uiSchemaTemplates_exports = {};
|
|
28
|
-
__export(uiSchemaTemplates_exports, {
|
|
29
|
-
default: () => uiSchemaTemplates_default
|
|
30
|
-
});
|
|
31
|
-
module.exports = __toCommonJS(uiSchemaTemplates_exports);
|
|
32
|
-
var import_database = require("@nocobase/database");
|
|
33
|
-
var uiSchemaTemplates_default = (0, import_database.defineCollection)({
|
|
34
|
-
dumpRules: "required",
|
|
35
|
-
name: "uiSchemaTemplates",
|
|
36
|
-
autoGenId: false,
|
|
37
|
-
fields: [
|
|
38
|
-
{
|
|
39
|
-
type: "uid",
|
|
40
|
-
name: "key",
|
|
41
|
-
primaryKey: true
|
|
42
|
-
},
|
|
43
|
-
{
|
|
44
|
-
type: "string",
|
|
45
|
-
name: "name",
|
|
46
|
-
translation: true
|
|
47
|
-
},
|
|
48
|
-
{
|
|
49
|
-
type: "string",
|
|
50
|
-
name: "componentName"
|
|
51
|
-
},
|
|
52
|
-
{
|
|
53
|
-
type: "string",
|
|
54
|
-
name: "associationName"
|
|
55
|
-
},
|
|
56
|
-
{
|
|
57
|
-
type: "string",
|
|
58
|
-
name: "resourceName"
|
|
59
|
-
},
|
|
60
|
-
{
|
|
61
|
-
type: "string",
|
|
62
|
-
name: "collectionName"
|
|
63
|
-
},
|
|
64
|
-
{
|
|
65
|
-
type: "string",
|
|
66
|
-
name: "dataSourceKey"
|
|
67
|
-
},
|
|
68
|
-
{
|
|
69
|
-
type: "belongsTo",
|
|
70
|
-
name: "uiSchema",
|
|
71
|
-
target: "uiSchemas",
|
|
72
|
-
foreignKey: "uid"
|
|
73
|
-
}
|
|
74
|
-
]
|
|
75
|
-
});
|
|
@@ -1,11 +0,0 @@
|
|
|
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 { CollectionOptions } from '@nocobase/database';
|
|
10
|
-
declare const _default: CollectionOptions;
|
|
11
|
-
export default _default;
|
|
@@ -1,73 +0,0 @@
|
|
|
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
|
-
|
|
10
|
-
var __defProp = Object.defineProperty;
|
|
11
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
12
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
13
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
14
|
-
var __export = (target, all) => {
|
|
15
|
-
for (var name in all)
|
|
16
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
17
|
-
};
|
|
18
|
-
var __copyProps = (to, from, except, desc) => {
|
|
19
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
20
|
-
for (let key of __getOwnPropNames(from))
|
|
21
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
22
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
23
|
-
}
|
|
24
|
-
return to;
|
|
25
|
-
};
|
|
26
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
27
|
-
var uiSchemaTreePath_exports = {};
|
|
28
|
-
__export(uiSchemaTreePath_exports, {
|
|
29
|
-
default: () => uiSchemaTreePath_default
|
|
30
|
-
});
|
|
31
|
-
module.exports = __toCommonJS(uiSchemaTreePath_exports);
|
|
32
|
-
var uiSchemaTreePath_default = {
|
|
33
|
-
dumpRules: "required",
|
|
34
|
-
name: "uiSchemaTreePath",
|
|
35
|
-
autoGenId: false,
|
|
36
|
-
timestamps: false,
|
|
37
|
-
indexes: [
|
|
38
|
-
{
|
|
39
|
-
fields: ["descendant"]
|
|
40
|
-
}
|
|
41
|
-
],
|
|
42
|
-
fields: [
|
|
43
|
-
{
|
|
44
|
-
type: "string",
|
|
45
|
-
name: "ancestor",
|
|
46
|
-
primaryKey: true
|
|
47
|
-
},
|
|
48
|
-
{
|
|
49
|
-
type: "string",
|
|
50
|
-
name: "descendant",
|
|
51
|
-
primaryKey: true,
|
|
52
|
-
index: true
|
|
53
|
-
},
|
|
54
|
-
{
|
|
55
|
-
type: "integer",
|
|
56
|
-
name: "depth"
|
|
57
|
-
},
|
|
58
|
-
{
|
|
59
|
-
type: "boolean",
|
|
60
|
-
name: "async"
|
|
61
|
-
},
|
|
62
|
-
{
|
|
63
|
-
type: "string",
|
|
64
|
-
name: "type",
|
|
65
|
-
comment: "type of node"
|
|
66
|
-
},
|
|
67
|
-
{
|
|
68
|
-
type: "integer",
|
|
69
|
-
name: "sort",
|
|
70
|
-
comment: "sort of node in adjacency"
|
|
71
|
-
}
|
|
72
|
-
]
|
|
73
|
-
};
|
|
@@ -1,11 +0,0 @@
|
|
|
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 { CollectionOptions } from '@nocobase/database';
|
|
10
|
-
declare const _default: CollectionOptions;
|
|
11
|
-
export default _default;
|
|
@@ -1,62 +0,0 @@
|
|
|
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
|
-
|
|
10
|
-
var __defProp = Object.defineProperty;
|
|
11
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
12
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
13
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
14
|
-
var __export = (target, all) => {
|
|
15
|
-
for (var name in all)
|
|
16
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
17
|
-
};
|
|
18
|
-
var __copyProps = (to, from, except, desc) => {
|
|
19
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
20
|
-
for (let key of __getOwnPropNames(from))
|
|
21
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
22
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
23
|
-
}
|
|
24
|
-
return to;
|
|
25
|
-
};
|
|
26
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
27
|
-
var uiSchemas_exports = {};
|
|
28
|
-
__export(uiSchemas_exports, {
|
|
29
|
-
default: () => uiSchemas_default
|
|
30
|
-
});
|
|
31
|
-
module.exports = __toCommonJS(uiSchemas_exports);
|
|
32
|
-
var uiSchemas_default = {
|
|
33
|
-
dumpRules: "required",
|
|
34
|
-
name: "uiSchemas",
|
|
35
|
-
autoGenId: false,
|
|
36
|
-
timestamps: false,
|
|
37
|
-
repository: "UiSchemaRepository",
|
|
38
|
-
model: "UiSchemaModel",
|
|
39
|
-
magicAttribute: "schema",
|
|
40
|
-
fields: [
|
|
41
|
-
{
|
|
42
|
-
type: "uid",
|
|
43
|
-
name: "x-uid",
|
|
44
|
-
primaryKey: true
|
|
45
|
-
},
|
|
46
|
-
{
|
|
47
|
-
type: "string",
|
|
48
|
-
name: "name"
|
|
49
|
-
},
|
|
50
|
-
{
|
|
51
|
-
type: "hasMany",
|
|
52
|
-
name: "serverHooks",
|
|
53
|
-
target: "uiSchemaServerHooks",
|
|
54
|
-
foreignKey: "uid"
|
|
55
|
-
},
|
|
56
|
-
{
|
|
57
|
-
type: "json",
|
|
58
|
-
name: "schema",
|
|
59
|
-
defaultValue: {}
|
|
60
|
-
}
|
|
61
|
-
]
|
|
62
|
-
};
|
|
@@ -1,26 +0,0 @@
|
|
|
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
|
-
export interface TargetPosition {
|
|
10
|
-
type: 'before' | 'after';
|
|
11
|
-
target: string;
|
|
12
|
-
}
|
|
13
|
-
export interface ChildOptions {
|
|
14
|
-
parentUid: string;
|
|
15
|
-
parentPath?: string[];
|
|
16
|
-
type: string;
|
|
17
|
-
position?: 'first' | 'last' | TargetPosition;
|
|
18
|
-
sort?: number;
|
|
19
|
-
}
|
|
20
|
-
export interface SchemaNode {
|
|
21
|
-
name: string;
|
|
22
|
-
'x-uid': string;
|
|
23
|
-
schema: object;
|
|
24
|
-
'x-async'?: boolean;
|
|
25
|
-
childOptions?: ChildOptions;
|
|
26
|
-
}
|
|
@@ -1,24 +0,0 @@
|
|
|
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
|
-
|
|
10
|
-
var __defProp = Object.defineProperty;
|
|
11
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
12
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
13
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
14
|
-
var __copyProps = (to, from, except, desc) => {
|
|
15
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
16
|
-
for (let key of __getOwnPropNames(from))
|
|
17
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
18
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
19
|
-
}
|
|
20
|
-
return to;
|
|
21
|
-
};
|
|
22
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
23
|
-
var ui_schema_node_dao_exports = {};
|
|
24
|
-
module.exports = __toCommonJS(ui_schema_node_dao_exports);
|
package/dist/server/helper.d.ts
DELETED
|
@@ -1,8 +0,0 @@
|
|
|
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
|
-
*/
|