@nocobase/plugin-data-source-manager 1.3.0-alpha.20240710084543 → 1.3.0-alpha.20240710155619

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (113) hide show
  1. package/dist/client/DatabaseConnectionProvider.d.ts +11 -0
  2. package/dist/client/ThridDataSource.d.ts +12 -0
  3. package/dist/client/component/BreadcumbTitle.d.ts +10 -0
  4. package/dist/client/component/CollectionsManager/AddFieldAction.d.ts +13 -0
  5. package/dist/client/component/CollectionsManager/CollectionFields.d.ts +16 -0
  6. package/dist/client/component/CollectionsManager/CollectionTitle.d.ts +9 -0
  7. package/dist/client/component/CollectionsManager/ConfigurationTable.d.ts +10 -0
  8. package/dist/client/component/CollectionsManager/ConfigurationTabs.d.ts +10 -0
  9. package/dist/client/component/CollectionsManager/EditCollectionAction.d.ts +14 -0
  10. package/dist/client/component/CollectionsManager/EditFieldAction.d.ts +10 -0
  11. package/dist/client/component/CollectionsManager/FilterTargetKeyAlert.d.ts +12 -0
  12. package/dist/client/component/CollectionsManager/SetFilterTargetKey.d.ts +10 -0
  13. package/dist/client/component/CollectionsManager/components/CollectionFieldInterfaceSelect.d.ts +10 -0
  14. package/dist/client/component/CollectionsManager/components/CollectionName.d.ts +9 -0
  15. package/dist/client/component/CollectionsManager/components/FieldTitleInput.d.ts +10 -0
  16. package/dist/client/component/CollectionsManager/components/FieldType.d.ts +10 -0
  17. package/dist/client/component/CollectionsManager/components/TitleField.d.ts +10 -0
  18. package/dist/client/component/CollectionsManager/components/UnSupportFields.d.ts +10 -0
  19. package/dist/client/component/CollectionsManager/components/index.d.ts +14 -0
  20. package/dist/client/component/CollectionsManager/hooks.d.ts +20 -0
  21. package/dist/client/component/CollectionsManager/index.d.ts +10 -0
  22. package/dist/client/component/CollectionsManager/schema/collectionFields.d.ts +12 -0
  23. package/dist/client/component/CollectionsManager/schema/collections.d.ts +72 -0
  24. package/dist/client/component/CreateDatabaseConnectAction.d.ts +10 -0
  25. package/dist/client/component/DatabaseConnectionManager.d.ts +10 -0
  26. package/dist/client/component/EditDatabaseConnectionAction.d.ts +10 -0
  27. package/dist/client/component/MainDataSourceManager/Configuration/AddCategoryAction.d.ts +11 -0
  28. package/dist/client/component/MainDataSourceManager/Configuration/CollectionFields.d.ts +11 -0
  29. package/dist/client/component/MainDataSourceManager/Configuration/ConfigurationTable.d.ts +10 -0
  30. package/dist/client/component/MainDataSourceManager/Configuration/ConfigurationTabs.d.ts +10 -0
  31. package/dist/client/component/MainDataSourceManager/Configuration/EditCategoryAction.d.ts +11 -0
  32. package/dist/client/component/MainDataSourceManager/Configuration/index.d.ts +13 -0
  33. package/dist/client/component/MainDataSourceManager/Configuration/interfaces.d.ts +24 -0
  34. package/dist/client/component/MainDataSourceManager/Configuration/schemas/collectionFields.d.ts +10 -0
  35. package/dist/client/component/MainDataSourceManager/Configuration/schemas/collections.d.ts +15 -0
  36. package/dist/client/component/MainDataSourceManager/index.d.ts +10 -0
  37. package/dist/client/component/PermissionManager/DataSourceTable.d.ts +11 -0
  38. package/dist/client/component/PermissionManager/PermisionProvider.d.ts +13 -0
  39. package/dist/client/component/PermissionManager/RoleConfigure.d.ts +10 -0
  40. package/dist/client/component/PermissionManager/RolesResourcesActions.d.ts +11 -0
  41. package/dist/client/component/PermissionManager/ScopeSelect.d.ts +11 -0
  42. package/dist/client/component/PermissionManager/StrategyActions.d.ts +10 -0
  43. package/dist/client/component/PermissionManager/index.d.ts +11 -0
  44. package/dist/client/component/PermissionManager/schemas/dataSourceTable.d.ts +10 -0
  45. package/dist/client/component/PermissionManager/schemas/roleCollections.d.ts +10 -0
  46. package/dist/client/component/PermissionManager/schemas/scopes.d.ts +130 -0
  47. package/dist/client/component/PermissionManager/schemas/useRoleResourceValues.d.ts +16 -0
  48. package/dist/client/component/PermissionManager/schemas/useSaveRoleResourceAction.d.ts +11 -0
  49. package/dist/client/component/PermissionManager/style.d.ts +9 -0
  50. package/dist/client/component/ViewDatabaseConnectionAction.d.ts +10 -0
  51. package/dist/client/constant.d.ts +9 -0
  52. package/dist/client/hooks/index.d.ts +14 -0
  53. package/dist/client/index.d.ts +17 -0
  54. package/dist/client/index.js +59 -0
  55. package/dist/client/locale/index.d.ts +11 -0
  56. package/dist/client/schema/index.d.ts +15 -0
  57. package/dist/externalVersion.js +33 -0
  58. package/dist/index.d.ts +10 -0
  59. package/dist/index.js +48 -0
  60. package/dist/locale/zh-CN.json +40 -0
  61. package/dist/server/collections/data-sources-collections.d.ts +10 -0
  62. package/dist/server/collections/data-sources-collections.js +75 -0
  63. package/dist/server/collections/data-sources-fields.d.ts +10 -0
  64. package/dist/server/collections/data-sources-fields.js +96 -0
  65. package/dist/server/collections/data-sources-roles-resources-actions.d.ts +10 -0
  66. package/dist/server/collections/data-sources-roles-resources-actions.js +61 -0
  67. package/dist/server/collections/data-sources-roles-resources-scopes.d.ts +10 -0
  68. package/dist/server/collections/data-sources-roles-resources-scopes.js +65 -0
  69. package/dist/server/collections/data-sources-roles-resources.d.ts +10 -0
  70. package/dist/server/collections/data-sources-roles-resources.js +71 -0
  71. package/dist/server/collections/data-sources-roles.d.ts +10 -0
  72. package/dist/server/collections/data-sources-roles.js +63 -0
  73. package/dist/server/collections/data-sources.d.ts +10 -0
  74. package/dist/server/collections/data-sources.js +80 -0
  75. package/dist/server/errors/type-infer-error.d.ts +10 -0
  76. package/dist/server/errors/type-infer-error.js +37 -0
  77. package/dist/server/index.d.ts +10 -0
  78. package/dist/server/index.js +48 -0
  79. package/dist/server/migrations/20240301164024-migrate-acl-resources.d.ts +15 -0
  80. package/dist/server/migrations/20240301164024-migrate-acl-resources.js +127 -0
  81. package/dist/server/migrations/20240414103927-update-snippet-name.d.ts +14 -0
  82. package/dist/server/migrations/20240414103927-update-snippet-name.js +60 -0
  83. package/dist/server/models/connections-roles-resources-action.d.ts +11 -0
  84. package/dist/server/models/connections-roles-resources-action.js +38 -0
  85. package/dist/server/models/connections-roles-resources.d.ts +11 -0
  86. package/dist/server/models/connections-roles-resources.js +38 -0
  87. package/dist/server/models/data-source.d.ts +25 -0
  88. package/dist/server/models/data-source.js +173 -0
  89. package/dist/server/models/data-sources-collection-model.d.ts +15 -0
  90. package/dist/server/models/data-sources-collection-model.js +46 -0
  91. package/dist/server/models/data-sources-field-model.d.ts +18 -0
  92. package/dist/server/models/data-sources-field-model.js +63 -0
  93. package/dist/server/models/data-sources-roles-model.d.ts +17 -0
  94. package/dist/server/models/data-sources-roles-model.js +64 -0
  95. package/dist/server/plugin.d.ts +21 -0
  96. package/dist/server/plugin.js +443 -0
  97. package/dist/server/resourcers/data-sources-collections-fields.d.ts +19 -0
  98. package/dist/server/resourcers/data-sources-collections-fields.js +140 -0
  99. package/dist/server/resourcers/data-sources-collections.d.ts +16 -0
  100. package/dist/server/resourcers/data-sources-collections.js +115 -0
  101. package/dist/server/resourcers/data-sources-resources.d.ts +17 -0
  102. package/dist/server/resourcers/data-sources-resources.js +97 -0
  103. package/dist/server/resourcers/data-sources-roles.d.ts +16 -0
  104. package/dist/server/resourcers/data-sources-roles.js +98 -0
  105. package/dist/server/resourcers/roles-data-sources-collections.d.ts +15 -0
  106. package/dist/server/resourcers/roles-data-sources-collections.js +111 -0
  107. package/dist/server/services/full-data-repository.d.ts +16 -0
  108. package/dist/server/services/full-data-repository.js +60 -0
  109. package/dist/server/services/type-interface-map.d.ts +202 -0
  110. package/dist/server/services/type-interface-map.js +267 -0
  111. package/dist/server/utils.d.ts +9 -0
  112. package/dist/server/utils.js +47 -0
  113. package/package.json +2 -2
@@ -0,0 +1,60 @@
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 full_data_repository_exports = {};
28
+ __export(full_data_repository_exports, {
29
+ FullDataRepository: () => FullDataRepository
30
+ });
31
+ module.exports = __toCommonJS(full_data_repository_exports);
32
+ class FullDataRepository {
33
+ data = [];
34
+ constructor(data) {
35
+ this.data = data;
36
+ }
37
+ async count(countOptions) {
38
+ return this.data.length;
39
+ }
40
+ async find(options) {
41
+ const { limit, offset } = options || {};
42
+ let results = this.data;
43
+ if (offset) {
44
+ results = results.slice(offset);
45
+ }
46
+ if (limit) {
47
+ results = results.slice(0, limit);
48
+ }
49
+ return results;
50
+ }
51
+ async findAndCount(options = {}) {
52
+ const count = await this.count();
53
+ const results = count ? await this.find(options) : [];
54
+ return [results, count];
55
+ }
56
+ }
57
+ // Annotate the CommonJS export names for ESM import in node:
58
+ 0 && (module.exports = {
59
+ FullDataRepository
60
+ });
@@ -0,0 +1,202 @@
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 typeInterfaceMap: {
10
+ array: () => {
11
+ interface: string;
12
+ uiSchema: {
13
+ 'x-component': string;
14
+ 'x-component-props': {
15
+ autoSize: {
16
+ minRows: number;
17
+ };
18
+ };
19
+ default: any;
20
+ };
21
+ };
22
+ belongsTo: string;
23
+ belongsToMany: string;
24
+ boolean: () => {
25
+ interface: string;
26
+ uiSchema: {
27
+ type: string;
28
+ 'x-component': string;
29
+ };
30
+ };
31
+ context: string;
32
+ date: () => {
33
+ interface: string;
34
+ uiSchema: {
35
+ 'x-component': string;
36
+ 'x-component-props': {
37
+ dateFormat: string;
38
+ showTime: boolean;
39
+ };
40
+ };
41
+ };
42
+ hasMany: string;
43
+ hasOne: string;
44
+ json: () => {
45
+ interface: string;
46
+ uiSchema: {
47
+ 'x-component': string;
48
+ 'x-component-props': {
49
+ autoSize: {
50
+ minRows: number;
51
+ };
52
+ };
53
+ default: any;
54
+ };
55
+ };
56
+ jsonb: () => {
57
+ interface: string;
58
+ uiSchema: {
59
+ 'x-component': string;
60
+ 'x-component-props': {
61
+ autoSize: {
62
+ minRows: number;
63
+ };
64
+ };
65
+ default: any;
66
+ };
67
+ };
68
+ integer: () => {
69
+ interface: string;
70
+ uiSchema: {
71
+ type: string;
72
+ 'x-component': string;
73
+ 'x-component-props': {
74
+ stringMode: boolean;
75
+ step: string;
76
+ };
77
+ 'x-validator': string;
78
+ };
79
+ };
80
+ bigInt: (columnInfo: any) => {
81
+ interface: string;
82
+ uiSchema: {
83
+ 'x-component': string;
84
+ 'x-component-props': {
85
+ style: {
86
+ width: string;
87
+ };
88
+ };
89
+ };
90
+ };
91
+ float: () => {
92
+ interface: string;
93
+ uiSchema: {
94
+ type: string;
95
+ 'x-component': string;
96
+ 'x-component-props': {
97
+ stringMode: boolean;
98
+ step: string;
99
+ };
100
+ };
101
+ };
102
+ double: () => {
103
+ interface: string;
104
+ uiSchema: {
105
+ type: string;
106
+ 'x-component': string;
107
+ 'x-component-props': {
108
+ stringMode: boolean;
109
+ step: string;
110
+ };
111
+ };
112
+ };
113
+ real: () => {
114
+ interface: string;
115
+ uiSchema: {
116
+ type: string;
117
+ 'x-component': string;
118
+ 'x-component-props': {
119
+ stringMode: boolean;
120
+ step: string;
121
+ };
122
+ };
123
+ };
124
+ decimal: () => {
125
+ interface: string;
126
+ uiSchema: {
127
+ type: string;
128
+ 'x-component': string;
129
+ 'x-component-props': {
130
+ stringMode: boolean;
131
+ step: string;
132
+ };
133
+ };
134
+ };
135
+ password: () => {
136
+ interface: string;
137
+ hidden: boolean;
138
+ uiSchema: {
139
+ type: string;
140
+ 'x-component': string;
141
+ };
142
+ };
143
+ radio: string;
144
+ set: string;
145
+ sort: string;
146
+ string: () => {
147
+ interface: string;
148
+ uiSchema: {
149
+ 'x-component': string;
150
+ 'x-component-props': {
151
+ style: {
152
+ width: string;
153
+ };
154
+ };
155
+ };
156
+ };
157
+ text: () => {
158
+ interface: string;
159
+ uiSchema: {
160
+ type: string;
161
+ 'x-component': string;
162
+ };
163
+ };
164
+ time: () => {
165
+ interface: string;
166
+ uiSchema: {
167
+ type: string;
168
+ 'x-component': string;
169
+ 'x-component-props': {
170
+ format: string;
171
+ };
172
+ };
173
+ };
174
+ uid: () => {
175
+ interface: string;
176
+ uiSchema: {
177
+ 'x-component': string;
178
+ 'x-component-props': {
179
+ style: {
180
+ width: string;
181
+ };
182
+ };
183
+ };
184
+ };
185
+ uuid: () => {
186
+ interface: string;
187
+ uiSchema: {
188
+ 'x-component': string;
189
+ 'x-component-props': {
190
+ style: {
191
+ width: string;
192
+ };
193
+ };
194
+ };
195
+ };
196
+ virtual: string;
197
+ point: string;
198
+ polygon: string;
199
+ lineString: string;
200
+ circle: string;
201
+ };
202
+ export default typeInterfaceMap;
@@ -0,0 +1,267 @@
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 type_interface_map_exports = {};
28
+ __export(type_interface_map_exports, {
29
+ default: () => type_interface_map_default
30
+ });
31
+ module.exports = __toCommonJS(type_interface_map_exports);
32
+ /* istanbul ignore file -- @preserve */
33
+ const typeInterfaceMap = {
34
+ array: () => {
35
+ return {
36
+ interface: "json",
37
+ uiSchema: {
38
+ "x-component": "Input.JSON",
39
+ "x-component-props": {
40
+ autoSize: {
41
+ minRows: 5
42
+ // maxRows: 20,
43
+ }
44
+ },
45
+ default: null
46
+ }
47
+ };
48
+ },
49
+ belongsTo: "",
50
+ belongsToMany: "",
51
+ boolean: () => {
52
+ return {
53
+ interface: "checkbox",
54
+ uiSchema: {
55
+ type: "boolean",
56
+ "x-component": "Checkbox"
57
+ }
58
+ };
59
+ },
60
+ context: "",
61
+ date: () => {
62
+ return {
63
+ interface: "datetime",
64
+ uiSchema: {
65
+ "x-component": "DatePicker",
66
+ "x-component-props": {
67
+ dateFormat: "YYYY-MM-DD",
68
+ showTime: false
69
+ }
70
+ }
71
+ };
72
+ },
73
+ hasMany: "",
74
+ hasOne: "",
75
+ json: () => {
76
+ return {
77
+ interface: "json",
78
+ uiSchema: {
79
+ "x-component": "Input.JSON",
80
+ "x-component-props": {
81
+ autoSize: {
82
+ minRows: 5
83
+ // maxRows: 20,
84
+ }
85
+ },
86
+ default: null
87
+ }
88
+ };
89
+ },
90
+ jsonb: () => {
91
+ return {
92
+ interface: "json",
93
+ uiSchema: {
94
+ "x-component": "Input.JSON",
95
+ "x-component-props": {
96
+ autoSize: {
97
+ minRows: 5
98
+ // maxRows: 20,
99
+ }
100
+ },
101
+ default: null
102
+ }
103
+ };
104
+ },
105
+ integer: () => ({
106
+ interface: "integer",
107
+ // name,
108
+ uiSchema: {
109
+ type: "number",
110
+ // title,
111
+ "x-component": "InputNumber",
112
+ "x-component-props": {
113
+ stringMode: true,
114
+ step: "1"
115
+ },
116
+ "x-validator": "integer"
117
+ }
118
+ }),
119
+ bigInt: (columnInfo) => {
120
+ return {
121
+ interface: "integer",
122
+ uiSchema: {
123
+ "x-component": "InputNumber",
124
+ "x-component-props": {
125
+ style: {
126
+ width: "100%"
127
+ }
128
+ }
129
+ }
130
+ };
131
+ },
132
+ float: () => {
133
+ return {
134
+ interface: "number",
135
+ uiSchema: {
136
+ type: "number",
137
+ // title,
138
+ "x-component": "InputNumber",
139
+ "x-component-props": {
140
+ stringMode: true,
141
+ step: "1"
142
+ }
143
+ }
144
+ };
145
+ },
146
+ double: () => {
147
+ return {
148
+ interface: "number",
149
+ uiSchema: {
150
+ type: "number",
151
+ // title,
152
+ "x-component": "InputNumber",
153
+ "x-component-props": {
154
+ stringMode: true,
155
+ step: "1"
156
+ }
157
+ }
158
+ };
159
+ },
160
+ real: () => {
161
+ return {
162
+ interface: "number",
163
+ uiSchema: {
164
+ type: "number",
165
+ // title,
166
+ "x-component": "InputNumber",
167
+ "x-component-props": {
168
+ stringMode: true,
169
+ step: "1"
170
+ }
171
+ }
172
+ };
173
+ },
174
+ decimal: () => {
175
+ return {
176
+ interface: "number",
177
+ uiSchema: {
178
+ type: "number",
179
+ // title,
180
+ "x-component": "InputNumber",
181
+ "x-component-props": {
182
+ stringMode: true,
183
+ step: "1"
184
+ }
185
+ }
186
+ };
187
+ },
188
+ password: () => ({
189
+ interface: "password",
190
+ hidden: true,
191
+ // name,
192
+ uiSchema: {
193
+ type: "string",
194
+ // title,
195
+ "x-component": "Password"
196
+ }
197
+ }),
198
+ radio: "",
199
+ set: "",
200
+ sort: "",
201
+ string: () => {
202
+ return {
203
+ interface: "input",
204
+ uiSchema: {
205
+ "x-component": "Input",
206
+ "x-component-props": {
207
+ style: {
208
+ width: "100%"
209
+ }
210
+ }
211
+ }
212
+ };
213
+ },
214
+ text: () => {
215
+ return {
216
+ interface: "textarea",
217
+ // name,
218
+ uiSchema: {
219
+ type: "string",
220
+ "x-component": "Input.TextArea"
221
+ }
222
+ };
223
+ },
224
+ time: () => ({
225
+ interface: "time",
226
+ // name,
227
+ uiSchema: {
228
+ type: "string",
229
+ "x-component": "TimePicker",
230
+ "x-component-props": {
231
+ format: "HH:mm:ss"
232
+ }
233
+ }
234
+ }),
235
+ uid: () => {
236
+ return {
237
+ interface: "input",
238
+ uiSchema: {
239
+ "x-component": "Input",
240
+ "x-component-props": {
241
+ style: {
242
+ width: "100%"
243
+ }
244
+ }
245
+ }
246
+ };
247
+ },
248
+ uuid: () => {
249
+ return {
250
+ interface: "input",
251
+ uiSchema: {
252
+ "x-component": "Input",
253
+ "x-component-props": {
254
+ style: {
255
+ width: "100%"
256
+ }
257
+ }
258
+ }
259
+ };
260
+ },
261
+ virtual: "",
262
+ point: "",
263
+ polygon: "",
264
+ lineString: "",
265
+ circle: ""
266
+ };
267
+ var type_interface_map_default = typeInterfaceMap;
@@ -0,0 +1,9 @@
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 declare function mergeOptions(fieldOptions: any, modelOptions: any): any;
@@ -0,0 +1,47 @@
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 utils_exports = {};
28
+ __export(utils_exports, {
29
+ mergeOptions: () => mergeOptions
30
+ });
31
+ module.exports = __toCommonJS(utils_exports);
32
+ function mergeOptions(fieldOptions, modelOptions) {
33
+ const newOptions = {
34
+ ...fieldOptions,
35
+ ...modelOptions
36
+ };
37
+ for (const key of Object.keys(modelOptions)) {
38
+ if (modelOptions[key] === null && fieldOptions[key]) {
39
+ newOptions[key] = fieldOptions[key];
40
+ }
41
+ }
42
+ return newOptions;
43
+ }
44
+ // Annotate the CommonJS export names for ESM import in node:
45
+ 0 && (module.exports = {
46
+ mergeOptions
47
+ });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nocobase/plugin-data-source-manager",
3
- "version": "1.3.0-alpha.20240710084543",
3
+ "version": "1.3.0-alpha.20240710155619",
4
4
  "main": "dist/server/index.js",
5
5
  "displayName": "Data source manager",
6
6
  "displayName.zh-CN": "数据源管理",
@@ -16,5 +16,5 @@
16
16
  "keywords": [
17
17
  "Data model tools"
18
18
  ],
19
- "gitHead": "07a8b596fc64a9779a194cb9b0dc2ca7570ed9d4"
19
+ "gitHead": "95de9b94409d2e98bc2b95161ddf2012499bb5ec"
20
20
  }