@nocobase/client 0.7.5-alpha.1 → 0.7.6-alpha.2
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/es/application/Application.js +1 -3
- package/es/collection-manager/Configuration/ConfigurationTable.js +8 -3
- package/es/collection-manager/Configuration/schemas/collections.d.ts +2 -0
- package/es/collection-manager/Configuration/schemas/collections.js +23 -1
- package/es/collection-manager/action-hooks.d.ts +5 -0
- package/es/collection-manager/action-hooks.js +14 -1
- package/es/index.d.ts +0 -1
- package/es/index.js +0 -1
- package/es/locale/index.js +14 -2
- package/es/locale/tr_TR.d.ts +560 -0
- package/es/locale/tr_TR.js +559 -0
- package/es/locale/zh_CN.d.ts +3 -0
- package/es/locale/zh_CN.js +4 -1
- package/es/schema-component/antd/filter/useFilterActionProps.d.ts +12 -1
- package/es/schema-component/antd/filter/useFilterActionProps.js +24 -10
- package/es/schema-component/antd/filter/useValues.js +0 -1
- package/es/user/SignupPage.d.ts +6 -1
- package/es/user/SignupPage.js +4 -2
- package/lib/application/Application.js +1 -4
- package/lib/collection-manager/Configuration/ConfigurationTable.js +7 -2
- package/lib/collection-manager/Configuration/schemas/collections.d.ts +2 -0
- package/lib/collection-manager/Configuration/schemas/collections.js +24 -1
- package/lib/collection-manager/action-hooks.d.ts +5 -0
- package/lib/collection-manager/action-hooks.js +31 -14
- package/lib/index.d.ts +0 -1
- package/lib/index.js +0 -13
- package/lib/locale/index.js +18 -4
- package/lib/locale/tr_TR.d.ts +560 -0
- package/lib/locale/tr_TR.js +566 -0
- package/lib/locale/zh_CN.d.ts +3 -0
- package/lib/locale/zh_CN.js +4 -1
- package/lib/schema-component/antd/filter/useFilterActionProps.d.ts +12 -1
- package/lib/schema-component/antd/filter/useFilterActionProps.js +34 -11
- package/lib/schema-component/antd/filter/useValues.js +0 -1
- package/lib/user/SignupPage.d.ts +6 -1
- package/lib/user/SignupPage.js +4 -2
- package/package.json +4 -4
- package/es/file-manager/FileStorageShortcut.d.ts +0 -1
- package/es/file-manager/FileStorageShortcut.js +0 -61
- package/es/file-manager/StorageOptions.d.ts +0 -2
- package/es/file-manager/StorageOptions.js +0 -121
- package/es/file-manager/index.d.ts +0 -1
- package/es/file-manager/index.js +0 -1
- package/es/file-manager/schemas/storage.d.ts +0 -2
- package/es/file-manager/schemas/storage.js +0 -349
- package/lib/file-manager/FileStorageShortcut.d.ts +0 -1
- package/lib/file-manager/FileStorageShortcut.js +0 -85
- package/lib/file-manager/StorageOptions.d.ts +0 -2
- package/lib/file-manager/StorageOptions.js +0 -138
- package/lib/file-manager/index.d.ts +0 -1
- package/lib/file-manager/index.js +0 -18
- package/lib/file-manager/schemas/storage.d.ts +0 -2
- package/lib/file-manager/schemas/storage.js +0 -360
|
@@ -1,360 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.storageSchema = void 0;
|
|
7
|
-
|
|
8
|
-
var _shared = require("@formily/shared");
|
|
9
|
-
|
|
10
|
-
var _apiClient = require("../../api-client");
|
|
11
|
-
|
|
12
|
-
var _schemaComponent = require("../../schema-component");
|
|
13
|
-
|
|
14
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
15
|
-
|
|
16
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
17
|
-
|
|
18
|
-
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
19
|
-
|
|
20
|
-
var collection = {
|
|
21
|
-
name: 'storages',
|
|
22
|
-
fields: [{
|
|
23
|
-
type: 'integer',
|
|
24
|
-
name: 'title',
|
|
25
|
-
interface: 'input',
|
|
26
|
-
uiSchema: {
|
|
27
|
-
title: '{{t("Storage display name")}}',
|
|
28
|
-
type: 'string',
|
|
29
|
-
'x-component': 'Input',
|
|
30
|
-
required: true
|
|
31
|
-
}
|
|
32
|
-
}, {
|
|
33
|
-
type: 'string',
|
|
34
|
-
name: 'name',
|
|
35
|
-
interface: 'input',
|
|
36
|
-
uiSchema: {
|
|
37
|
-
title: '{{t("Storage name")}}',
|
|
38
|
-
type: 'string',
|
|
39
|
-
'x-component': 'Input'
|
|
40
|
-
}
|
|
41
|
-
}, {
|
|
42
|
-
type: 'string',
|
|
43
|
-
name: 'type',
|
|
44
|
-
interface: 'select',
|
|
45
|
-
uiSchema: {
|
|
46
|
-
title: '{{t("Storage type")}}',
|
|
47
|
-
type: 'string',
|
|
48
|
-
'x-component': 'Select',
|
|
49
|
-
required: true,
|
|
50
|
-
enum: [{
|
|
51
|
-
label: '{{t("Local storage")}}',
|
|
52
|
-
value: 'local'
|
|
53
|
-
}, {
|
|
54
|
-
label: '{{t("Aliyun OSS")}}',
|
|
55
|
-
value: 'ali-oss'
|
|
56
|
-
}, {
|
|
57
|
-
label: '{{t("Amazon S3")}}',
|
|
58
|
-
value: 's3'
|
|
59
|
-
}]
|
|
60
|
-
}
|
|
61
|
-
}, {
|
|
62
|
-
type: 'string',
|
|
63
|
-
name: 'baseUrl',
|
|
64
|
-
interface: 'input',
|
|
65
|
-
uiSchema: {
|
|
66
|
-
title: '{{t("Storage base URL")}}',
|
|
67
|
-
type: 'string',
|
|
68
|
-
'x-component': 'Input'
|
|
69
|
-
}
|
|
70
|
-
}, {
|
|
71
|
-
type: 'boolean',
|
|
72
|
-
name: 'default',
|
|
73
|
-
interface: 'boolean',
|
|
74
|
-
uiSchema: {
|
|
75
|
-
title: '{{t("Default storage")}}',
|
|
76
|
-
type: 'boolean',
|
|
77
|
-
'x-component': 'Checkbox'
|
|
78
|
-
}
|
|
79
|
-
}]
|
|
80
|
-
};
|
|
81
|
-
var storageSchema = {
|
|
82
|
-
type: 'object',
|
|
83
|
-
properties: {
|
|
84
|
-
block1: {
|
|
85
|
-
type: 'void',
|
|
86
|
-
'x-decorator': 'ResourceActionProvider',
|
|
87
|
-
'x-decorator-props': {
|
|
88
|
-
collection: collection,
|
|
89
|
-
resourceName: 'storages',
|
|
90
|
-
request: {
|
|
91
|
-
resource: 'storages',
|
|
92
|
-
action: 'list',
|
|
93
|
-
params: {
|
|
94
|
-
pageSize: 50,
|
|
95
|
-
sort: ['id'],
|
|
96
|
-
appends: []
|
|
97
|
-
}
|
|
98
|
-
}
|
|
99
|
-
},
|
|
100
|
-
'x-component': 'CollectionProvider',
|
|
101
|
-
'x-component-props': {
|
|
102
|
-
collection: collection
|
|
103
|
-
},
|
|
104
|
-
properties: {
|
|
105
|
-
actions: {
|
|
106
|
-
type: 'void',
|
|
107
|
-
'x-component': 'ActionBar',
|
|
108
|
-
'x-component-props': {
|
|
109
|
-
style: {
|
|
110
|
-
marginBottom: 16
|
|
111
|
-
}
|
|
112
|
-
},
|
|
113
|
-
properties: {
|
|
114
|
-
delete: {
|
|
115
|
-
type: 'void',
|
|
116
|
-
title: '{{ t("Delete") }}',
|
|
117
|
-
'x-component': 'Action',
|
|
118
|
-
'x-component-props': {
|
|
119
|
-
useAction: '{{ cm.useBulkDestroyAction }}',
|
|
120
|
-
confirm: {
|
|
121
|
-
title: "{{t('Delete storage')}}",
|
|
122
|
-
content: "{{t('Are you sure you want to delete it?')}}"
|
|
123
|
-
}
|
|
124
|
-
}
|
|
125
|
-
},
|
|
126
|
-
create: {
|
|
127
|
-
type: 'void',
|
|
128
|
-
title: '{{t("Add storage")}}',
|
|
129
|
-
'x-component': 'Action',
|
|
130
|
-
'x-component-props': {
|
|
131
|
-
type: 'primary'
|
|
132
|
-
},
|
|
133
|
-
properties: {
|
|
134
|
-
drawer: {
|
|
135
|
-
type: 'void',
|
|
136
|
-
'x-component': 'Action.Drawer',
|
|
137
|
-
'x-decorator': 'Form',
|
|
138
|
-
'x-decorator-props': {
|
|
139
|
-
useValues: function useValues(options) {
|
|
140
|
-
var ctx = (0, _schemaComponent.useActionContext)();
|
|
141
|
-
return (0, _apiClient.useRequest)(function () {
|
|
142
|
-
return Promise.resolve({
|
|
143
|
-
data: {
|
|
144
|
-
name: "s_".concat((0, _shared.uid)())
|
|
145
|
-
}
|
|
146
|
-
});
|
|
147
|
-
}, _objectSpread(_objectSpread({}, options), {}, {
|
|
148
|
-
refreshDeps: [ctx.visible]
|
|
149
|
-
}));
|
|
150
|
-
}
|
|
151
|
-
},
|
|
152
|
-
title: '{{t("Add storage")}}',
|
|
153
|
-
properties: {
|
|
154
|
-
title: {
|
|
155
|
-
'x-component': 'CollectionField',
|
|
156
|
-
'x-decorator': 'FormItem'
|
|
157
|
-
},
|
|
158
|
-
name: {
|
|
159
|
-
'x-component': 'CollectionField',
|
|
160
|
-
'x-decorator': 'FormItem',
|
|
161
|
-
description: '{{t("Randomly generated and can be modified. Support letters, numbers and underscores, must start with an letter.")}}'
|
|
162
|
-
},
|
|
163
|
-
baseUrl: {
|
|
164
|
-
'x-component': 'CollectionField',
|
|
165
|
-
'x-decorator': 'FormItem'
|
|
166
|
-
},
|
|
167
|
-
type: {
|
|
168
|
-
'x-component': 'CollectionField',
|
|
169
|
-
'x-decorator': 'FormItem'
|
|
170
|
-
},
|
|
171
|
-
options: {
|
|
172
|
-
type: 'object',
|
|
173
|
-
'x-component': 'StorageOptions'
|
|
174
|
-
},
|
|
175
|
-
default: {
|
|
176
|
-
'x-component': 'CollectionField',
|
|
177
|
-
'x-decorator': 'FormItem',
|
|
178
|
-
title: '',
|
|
179
|
-
'x-content': '{{t("Default storage")}}'
|
|
180
|
-
},
|
|
181
|
-
footer: {
|
|
182
|
-
type: 'void',
|
|
183
|
-
'x-component': 'Action.Drawer.Footer',
|
|
184
|
-
properties: {
|
|
185
|
-
cancel: {
|
|
186
|
-
title: '{{t("Cancel")}}',
|
|
187
|
-
'x-component': 'Action',
|
|
188
|
-
'x-component-props': {
|
|
189
|
-
useAction: '{{ cm.useCancelAction }}'
|
|
190
|
-
}
|
|
191
|
-
},
|
|
192
|
-
submit: {
|
|
193
|
-
title: '{{t("Submit")}}',
|
|
194
|
-
'x-component': 'Action',
|
|
195
|
-
'x-component-props': {
|
|
196
|
-
type: 'primary',
|
|
197
|
-
useAction: '{{ cm.useCreateAction }}'
|
|
198
|
-
}
|
|
199
|
-
}
|
|
200
|
-
}
|
|
201
|
-
}
|
|
202
|
-
}
|
|
203
|
-
}
|
|
204
|
-
}
|
|
205
|
-
}
|
|
206
|
-
}
|
|
207
|
-
},
|
|
208
|
-
table: {
|
|
209
|
-
type: 'void',
|
|
210
|
-
'x-uid': 'input',
|
|
211
|
-
'x-component': 'Table.Void',
|
|
212
|
-
'x-component-props': {
|
|
213
|
-
rowKey: 'id',
|
|
214
|
-
rowSelection: {
|
|
215
|
-
type: 'checkbox'
|
|
216
|
-
},
|
|
217
|
-
useDataSource: '{{ cm.useDataSourceFromRAC }}'
|
|
218
|
-
},
|
|
219
|
-
properties: {
|
|
220
|
-
column1: {
|
|
221
|
-
type: 'void',
|
|
222
|
-
'x-decorator': 'Table.Column.Decorator',
|
|
223
|
-
'x-component': 'Table.Column',
|
|
224
|
-
properties: {
|
|
225
|
-
title: {
|
|
226
|
-
type: 'number',
|
|
227
|
-
'x-component': 'CollectionField',
|
|
228
|
-
'x-read-pretty': true
|
|
229
|
-
}
|
|
230
|
-
}
|
|
231
|
-
},
|
|
232
|
-
column2: {
|
|
233
|
-
type: 'void',
|
|
234
|
-
'x-decorator': 'Table.Column.Decorator',
|
|
235
|
-
'x-component': 'Table.Column',
|
|
236
|
-
properties: {
|
|
237
|
-
name: {
|
|
238
|
-
type: 'string',
|
|
239
|
-
'x-component': 'CollectionField',
|
|
240
|
-
'x-read-pretty': true
|
|
241
|
-
}
|
|
242
|
-
}
|
|
243
|
-
},
|
|
244
|
-
column3: {
|
|
245
|
-
type: 'void',
|
|
246
|
-
'x-decorator': 'Table.Column.Decorator',
|
|
247
|
-
'x-component': 'Table.Column',
|
|
248
|
-
properties: {
|
|
249
|
-
default: {
|
|
250
|
-
type: 'string',
|
|
251
|
-
'x-component': 'CollectionField',
|
|
252
|
-
'x-read-pretty': true
|
|
253
|
-
}
|
|
254
|
-
}
|
|
255
|
-
},
|
|
256
|
-
column4: {
|
|
257
|
-
type: 'void',
|
|
258
|
-
title: '{{t("Actions")}}',
|
|
259
|
-
'x-component': 'Table.Column',
|
|
260
|
-
properties: {
|
|
261
|
-
actions: {
|
|
262
|
-
type: 'void',
|
|
263
|
-
'x-component': 'Space',
|
|
264
|
-
'x-component-props': {
|
|
265
|
-
split: '|'
|
|
266
|
-
},
|
|
267
|
-
properties: {
|
|
268
|
-
update: {
|
|
269
|
-
type: 'void',
|
|
270
|
-
title: '{{t("Edit")}}',
|
|
271
|
-
'x-component': 'Action.Link',
|
|
272
|
-
'x-component-props': {
|
|
273
|
-
type: 'primary'
|
|
274
|
-
},
|
|
275
|
-
properties: {
|
|
276
|
-
drawer: {
|
|
277
|
-
type: 'void',
|
|
278
|
-
'x-component': 'Action.Drawer',
|
|
279
|
-
'x-decorator': 'Form',
|
|
280
|
-
'x-decorator-props': {
|
|
281
|
-
useValues: '{{ cm.useValuesFromRecord }}'
|
|
282
|
-
},
|
|
283
|
-
title: '{{t("Edit storage")}}',
|
|
284
|
-
properties: {
|
|
285
|
-
title: {
|
|
286
|
-
'x-component': 'CollectionField',
|
|
287
|
-
'x-decorator': 'FormItem'
|
|
288
|
-
},
|
|
289
|
-
name: {
|
|
290
|
-
'x-component': 'CollectionField',
|
|
291
|
-
'x-decorator': 'FormItem',
|
|
292
|
-
'x-disabled': true
|
|
293
|
-
},
|
|
294
|
-
baseUrl: {
|
|
295
|
-
'x-component': 'CollectionField',
|
|
296
|
-
'x-decorator': 'FormItem'
|
|
297
|
-
},
|
|
298
|
-
type: {
|
|
299
|
-
'x-component': 'CollectionField',
|
|
300
|
-
'x-decorator': 'FormItem',
|
|
301
|
-
'x-disabled': true
|
|
302
|
-
},
|
|
303
|
-
options: {
|
|
304
|
-
type: 'object',
|
|
305
|
-
'x-component': 'StorageOptions'
|
|
306
|
-
},
|
|
307
|
-
default: {
|
|
308
|
-
title: '',
|
|
309
|
-
'x-component': 'CollectionField',
|
|
310
|
-
'x-decorator': 'FormItem',
|
|
311
|
-
'x-content': '{{t("Default storage")}}'
|
|
312
|
-
},
|
|
313
|
-
footer: {
|
|
314
|
-
type: 'void',
|
|
315
|
-
'x-component': 'Action.Drawer.Footer',
|
|
316
|
-
properties: {
|
|
317
|
-
cancel: {
|
|
318
|
-
title: '{{t("Cancel")}}',
|
|
319
|
-
'x-component': 'Action',
|
|
320
|
-
'x-component-props': {
|
|
321
|
-
useAction: '{{ cm.useCancelAction }}'
|
|
322
|
-
}
|
|
323
|
-
},
|
|
324
|
-
submit: {
|
|
325
|
-
title: '{{t("Submit")}}',
|
|
326
|
-
'x-component': 'Action',
|
|
327
|
-
'x-component-props': {
|
|
328
|
-
type: 'primary',
|
|
329
|
-
useAction: '{{ cm.useUpdateAction }}'
|
|
330
|
-
}
|
|
331
|
-
}
|
|
332
|
-
}
|
|
333
|
-
}
|
|
334
|
-
}
|
|
335
|
-
}
|
|
336
|
-
}
|
|
337
|
-
},
|
|
338
|
-
delete: {
|
|
339
|
-
type: 'void',
|
|
340
|
-
title: '{{ t("Delete") }}',
|
|
341
|
-
'x-component': 'Action.Link',
|
|
342
|
-
'x-component-props': {
|
|
343
|
-
confirm: {
|
|
344
|
-
title: "{{t('Delete role')}}",
|
|
345
|
-
content: "{{t('Are you sure you want to delete it?')}}"
|
|
346
|
-
},
|
|
347
|
-
useAction: '{{cm.useDestroyAction}}'
|
|
348
|
-
}
|
|
349
|
-
}
|
|
350
|
-
}
|
|
351
|
-
}
|
|
352
|
-
}
|
|
353
|
-
}
|
|
354
|
-
}
|
|
355
|
-
}
|
|
356
|
-
}
|
|
357
|
-
}
|
|
358
|
-
}
|
|
359
|
-
};
|
|
360
|
-
exports.storageSchema = storageSchema;
|