@steedos-widgets/amis-lib 1.0.19 → 1.0.20
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/cjs/tsconfig.tsbuildinfo +1 -1
- package/dist/index.cjs.js +46 -17
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +46 -17
- package/dist/index.esm.js.map +1 -1
- package/dist/index.umd.js +184 -155
- package/dist/index.umd.js.map +1 -1
- package/dist/types/lib/converter/amis/header.d.ts +9 -2
- package/dist/types/lib/converter/amis/toolbar.d.ts +24 -1
- package/dist/types/lib/objects.d.ts +9 -61
- package/dist/types/lib/objectsRelated.d.ts +48 -51
- package/dist/types/lib/page_init.d.ts +1 -0
- package/package.json +2 -2
|
@@ -405,9 +405,17 @@ export function getObjectRecordDetailHeader(objectSchema: any, recordId: any, op
|
|
|
405
405
|
_id: any;
|
|
406
406
|
recordPermissions: any;
|
|
407
407
|
uiSchema: any;
|
|
408
|
+
record: string;
|
|
408
409
|
};
|
|
409
410
|
body: {
|
|
410
411
|
type: string;
|
|
412
|
+
data: {
|
|
413
|
+
"&": string;
|
|
414
|
+
objectName: any;
|
|
415
|
+
_id: any;
|
|
416
|
+
recordPermissions: string;
|
|
417
|
+
uiSchema: any;
|
|
418
|
+
};
|
|
411
419
|
body: {
|
|
412
420
|
type: string;
|
|
413
421
|
columns: ({
|
|
@@ -437,7 +445,6 @@ export function getObjectRecordDetailHeader(objectSchema: any, recordId: any, op
|
|
|
437
445
|
className: string;
|
|
438
446
|
}[];
|
|
439
447
|
md: string;
|
|
440
|
-
hiddenOn?: undefined;
|
|
441
448
|
} | {
|
|
442
449
|
body: {
|
|
443
450
|
type: string;
|
|
@@ -450,11 +457,11 @@ export function getObjectRecordDetailHeader(objectSchema: any, recordId: any, op
|
|
|
450
457
|
}[];
|
|
451
458
|
};
|
|
452
459
|
md: string;
|
|
453
|
-
hiddenOn: string;
|
|
454
460
|
})[];
|
|
455
461
|
className: string;
|
|
456
462
|
}[];
|
|
457
463
|
messages: {};
|
|
464
|
+
hiddenOn: string;
|
|
458
465
|
}[];
|
|
459
466
|
className: string;
|
|
460
467
|
}>;
|
|
@@ -1,4 +1,19 @@
|
|
|
1
|
-
export function getObjectHeaderToolbar(mainObject: any, formFactor: any
|
|
1
|
+
export function getObjectHeaderToolbar(mainObject: any, formFactor: any, { showDisplayAs }?: {
|
|
2
|
+
showDisplayAs?: boolean;
|
|
3
|
+
}): (string | {
|
|
4
|
+
type: string;
|
|
5
|
+
icon: string;
|
|
6
|
+
btnClassName: string;
|
|
7
|
+
align: string;
|
|
8
|
+
buttons: {
|
|
9
|
+
label: string;
|
|
10
|
+
children: {
|
|
11
|
+
type: string;
|
|
12
|
+
label: string;
|
|
13
|
+
onClick: string;
|
|
14
|
+
}[];
|
|
15
|
+
}[];
|
|
16
|
+
} | {
|
|
2
17
|
type: string;
|
|
3
18
|
className: string;
|
|
4
19
|
tpl?: undefined;
|
|
@@ -37,6 +52,14 @@ export function getObjectHeaderToolbar(mainObject: any, formFactor: any): (strin
|
|
|
37
52
|
};
|
|
38
53
|
};
|
|
39
54
|
tpl?: undefined;
|
|
55
|
+
} | {
|
|
56
|
+
type?: undefined;
|
|
57
|
+
className?: undefined;
|
|
58
|
+
tpl?: undefined;
|
|
59
|
+
align?: undefined;
|
|
60
|
+
label?: undefined;
|
|
61
|
+
icon?: undefined;
|
|
62
|
+
onEvent?: undefined;
|
|
40
63
|
})[];
|
|
41
64
|
export function getObjectFooterToolbar(mainObject: any, formFactor: any): string[];
|
|
42
65
|
export function getObjectFilter(objectSchema: any, fields: any, options: any): Promise<{
|
|
@@ -310,9 +310,17 @@ export function getRecordDetailHeaderSchema(objectName: any, recordId: any, opti
|
|
|
310
310
|
_id: any;
|
|
311
311
|
recordPermissions: any;
|
|
312
312
|
uiSchema: any;
|
|
313
|
+
record: string;
|
|
313
314
|
};
|
|
314
315
|
body: {
|
|
315
316
|
type: string;
|
|
317
|
+
data: {
|
|
318
|
+
"&": string;
|
|
319
|
+
objectName: any;
|
|
320
|
+
_id: any;
|
|
321
|
+
recordPermissions: string;
|
|
322
|
+
uiSchema: any;
|
|
323
|
+
};
|
|
316
324
|
body: {
|
|
317
325
|
type: string;
|
|
318
326
|
columns: ({
|
|
@@ -342,7 +350,6 @@ export function getRecordDetailHeaderSchema(objectName: any, recordId: any, opti
|
|
|
342
350
|
className: string;
|
|
343
351
|
}[];
|
|
344
352
|
md: string;
|
|
345
|
-
hiddenOn?: undefined;
|
|
346
353
|
} | {
|
|
347
354
|
body: {
|
|
348
355
|
type: string;
|
|
@@ -355,11 +362,11 @@ export function getRecordDetailHeaderSchema(objectName: any, recordId: any, opti
|
|
|
355
362
|
}[];
|
|
356
363
|
};
|
|
357
364
|
md: string;
|
|
358
|
-
hiddenOn: string;
|
|
359
365
|
})[];
|
|
360
366
|
className: string;
|
|
361
367
|
}[];
|
|
362
368
|
messages: {};
|
|
369
|
+
hiddenOn: string;
|
|
363
370
|
}[];
|
|
364
371
|
className: string;
|
|
365
372
|
};
|
|
@@ -412,65 +419,6 @@ export function getRecordDetailSchema(objectName: any, appId: any): Promise<{
|
|
|
412
419
|
})[];
|
|
413
420
|
};
|
|
414
421
|
}>;
|
|
415
|
-
export function getObjectRelatedList(appName: any, objectName: any, recordId: any, formFactor: any): Promise<({
|
|
416
|
-
masterObjectName: any;
|
|
417
|
-
object_name: any;
|
|
418
|
-
foreign_key: any;
|
|
419
|
-
label: any;
|
|
420
|
-
schema: {
|
|
421
|
-
uiSchema: any;
|
|
422
|
-
amisSchema: {
|
|
423
|
-
type: string;
|
|
424
|
-
className: string;
|
|
425
|
-
id: string;
|
|
426
|
-
name: string;
|
|
427
|
-
data: {
|
|
428
|
-
$master: string;
|
|
429
|
-
objectName: any;
|
|
430
|
-
_id: any;
|
|
431
|
-
recordPermissions: any;
|
|
432
|
-
uiSchema: any;
|
|
433
|
-
loaded: boolean;
|
|
434
|
-
};
|
|
435
|
-
body: {};
|
|
436
|
-
};
|
|
437
|
-
};
|
|
438
|
-
} | {
|
|
439
|
-
masterObjectName: any;
|
|
440
|
-
object_name: any;
|
|
441
|
-
foreign_key: any;
|
|
442
|
-
schema: {
|
|
443
|
-
uiSchema: any;
|
|
444
|
-
isCustomAmisSchema?: undefined;
|
|
445
|
-
amisSchema?: undefined;
|
|
446
|
-
isCalendar?: undefined;
|
|
447
|
-
} | {
|
|
448
|
-
uiSchema: any;
|
|
449
|
-
isCustomAmisSchema: boolean;
|
|
450
|
-
amisSchema: any;
|
|
451
|
-
isCalendar?: undefined;
|
|
452
|
-
} | {
|
|
453
|
-
uiSchema: any;
|
|
454
|
-
isCalendar: boolean;
|
|
455
|
-
amisSchema: any;
|
|
456
|
-
isCustomAmisSchema?: undefined;
|
|
457
|
-
} | {
|
|
458
|
-
uiSchema: any;
|
|
459
|
-
amisSchema: {
|
|
460
|
-
type: string;
|
|
461
|
-
objectApiName: any;
|
|
462
|
-
columns: any;
|
|
463
|
-
extraColumns: any;
|
|
464
|
-
filters: any;
|
|
465
|
-
filtersFunction: any;
|
|
466
|
-
sort: string;
|
|
467
|
-
ctx: {};
|
|
468
|
-
};
|
|
469
|
-
isCustomAmisSchema?: undefined;
|
|
470
|
-
isCalendar?: undefined;
|
|
471
|
-
};
|
|
472
|
-
label?: undefined;
|
|
473
|
-
})[]>;
|
|
474
422
|
export function getObjectRelated({ appName, masterObjectName, objectName, relatedFieldName, recordId, formFactor }: {
|
|
475
423
|
appName: any;
|
|
476
424
|
masterObjectName: any;
|
|
@@ -1,61 +1,25 @@
|
|
|
1
|
-
export function
|
|
1
|
+
export function getObjectRelatedList(appName: any, objectName: any, recordId: any, formFactor: any): Promise<({
|
|
2
2
|
masterObjectName: any;
|
|
3
3
|
object_name: any;
|
|
4
4
|
foreign_key: any;
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
name: string;
|
|
12
|
-
data: {
|
|
13
|
-
$master: string;
|
|
14
|
-
objectName: any;
|
|
15
|
-
_id: any;
|
|
16
|
-
recordPermissions: any;
|
|
17
|
-
uiSchema: any;
|
|
18
|
-
loaded: boolean;
|
|
19
|
-
};
|
|
20
|
-
body: {};
|
|
21
|
-
};
|
|
22
|
-
};
|
|
5
|
+
label: any;
|
|
6
|
+
columns: any;
|
|
7
|
+
sort: any;
|
|
8
|
+
filters: any;
|
|
9
|
+
visible_on: any;
|
|
10
|
+
page_size: any;
|
|
23
11
|
} | {
|
|
24
12
|
masterObjectName: any;
|
|
25
13
|
object_name: any;
|
|
26
14
|
foreign_key: any;
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
uiSchema: any;
|
|
34
|
-
isCustomAmisSchema: boolean;
|
|
35
|
-
amisSchema: any;
|
|
36
|
-
isCalendar?: undefined;
|
|
37
|
-
} | {
|
|
38
|
-
uiSchema: any;
|
|
39
|
-
isCalendar: boolean;
|
|
40
|
-
amisSchema: any;
|
|
41
|
-
isCustomAmisSchema?: undefined;
|
|
42
|
-
} | {
|
|
43
|
-
uiSchema: any;
|
|
44
|
-
amisSchema: {
|
|
45
|
-
type: string;
|
|
46
|
-
objectApiName: any;
|
|
47
|
-
columns: any;
|
|
48
|
-
extraColumns: any;
|
|
49
|
-
filters: any;
|
|
50
|
-
filtersFunction: any;
|
|
51
|
-
sort: string;
|
|
52
|
-
ctx: {};
|
|
53
|
-
};
|
|
54
|
-
isCustomAmisSchema?: undefined;
|
|
55
|
-
isCalendar?: undefined;
|
|
56
|
-
};
|
|
15
|
+
label?: undefined;
|
|
16
|
+
columns?: undefined;
|
|
17
|
+
sort?: undefined;
|
|
18
|
+
filters?: undefined;
|
|
19
|
+
visible_on?: undefined;
|
|
20
|
+
page_size?: undefined;
|
|
57
21
|
})[]>;
|
|
58
|
-
export function getRecordDetailRelatedListSchema(objectName: any, recordId: any, relatedObjectName: any, relatedKey: any,
|
|
22
|
+
export function getRecordDetailRelatedListSchema(objectName: any, recordId: any, relatedObjectName: any, relatedKey: any, ctx: any): Promise<{
|
|
59
23
|
uiSchema: any;
|
|
60
24
|
amisSchema: {
|
|
61
25
|
type: string;
|
|
@@ -71,7 +35,40 @@ export function getRecordDetailRelatedListSchema(objectName: any, recordId: any,
|
|
|
71
35
|
objectName: any;
|
|
72
36
|
listViewId: string;
|
|
73
37
|
};
|
|
74
|
-
body:
|
|
38
|
+
body: {
|
|
39
|
+
data: {
|
|
40
|
+
"&": string;
|
|
41
|
+
appId: string;
|
|
42
|
+
app_id: string;
|
|
43
|
+
relatedKey: any;
|
|
44
|
+
objectName: string;
|
|
45
|
+
recordId: string;
|
|
46
|
+
defaultData: {
|
|
47
|
+
[x: number]: any;
|
|
48
|
+
};
|
|
49
|
+
};
|
|
50
|
+
type: string;
|
|
51
|
+
objectApiName: any;
|
|
52
|
+
columns: any;
|
|
53
|
+
extraColumns: any;
|
|
54
|
+
filters: any;
|
|
55
|
+
filtersFunction: any;
|
|
56
|
+
sort: string;
|
|
57
|
+
ctx: {};
|
|
58
|
+
}[];
|
|
59
|
+
};
|
|
60
|
+
}>;
|
|
61
|
+
export function getRelatedListSchema(appName: any, objectName: any, listViewName: any, ctx?: {}): Promise<{
|
|
62
|
+
uiSchema: any;
|
|
63
|
+
amisSchema: {
|
|
64
|
+
type: string;
|
|
65
|
+
objectApiName: any;
|
|
66
|
+
columns: any;
|
|
67
|
+
extraColumns: any;
|
|
68
|
+
filters: any;
|
|
69
|
+
filtersFunction: any;
|
|
70
|
+
sort: string;
|
|
71
|
+
ctx: {};
|
|
75
72
|
};
|
|
76
73
|
}>;
|
|
77
74
|
export function getRelatedFieldValue(masterObjectName: any, record_id: any, uiSchema: any, foreign_key: any): any;
|
|
@@ -33,6 +33,7 @@ export function getListPageInitSchema(objectApiName: any, formFactor: any, userS
|
|
|
33
33
|
objectApiName: any;
|
|
34
34
|
columnsTogglable: boolean;
|
|
35
35
|
showHeader: boolean;
|
|
36
|
+
className: string;
|
|
36
37
|
}[];
|
|
37
38
|
}>;
|
|
38
39
|
export function getRecordPageInitSchema(objectApiName: any): Promise<{
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@steedos-widgets/amis-lib",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "1.0.
|
|
4
|
+
"version": "1.0.20",
|
|
5
5
|
"unpkg": "./dist/index.umd.js",
|
|
6
6
|
"main": "./dist/index.cjs.js",
|
|
7
7
|
"module": "./dist/index.esm.js",
|
|
@@ -58,5 +58,5 @@
|
|
|
58
58
|
"dependencies": {
|
|
59
59
|
"lodash": "^4.17.21"
|
|
60
60
|
},
|
|
61
|
-
"gitHead": "
|
|
61
|
+
"gitHead": "acf7c60bb6a47c4aa1a7b19dae65ccfe788b8557"
|
|
62
62
|
}
|