impaktapps-ui-builder 0.0.596 → 0.0.961
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/impaktapps-ui-builder.es.js +492 -359
- package/dist/impaktapps-ui-builder.es.js.map +1 -1
- package/dist/impaktapps-ui-builder.umd.js +16 -16
- package/dist/impaktapps-ui-builder.umd.js.map +1 -1
- package/dist/src/impaktapps-ui-builder/builder/build/buildCard.d.ts +1 -1
- package/dist/src/impaktapps-ui-builder/builder/build/buildTable.d.ts +0 -1
- package/dist/src/impaktapps-ui-builder/builder/build/buildUiSchema.d.ts +1 -1
- package/dist/src/impaktapps-ui-builder/builder/build/uischema/apiSection.d.ts +1 -0
- package/dist/src/impaktapps-ui-builder/builder/build/uischema/buildPropertiesSection.d.ts +23 -0
- package/dist/src/impaktapps-ui-builder/builder/build/uischema/card.d.ts +104 -83
- package/dist/src/impaktapps-ui-builder/builder/build/uischema/graph.d.ts +0 -1
- package/dist/src/impaktapps-ui-builder/builder/build/uischema/validationSections.d.ts +1 -1
- package/dist/src/impaktapps-ui-builder/builder/services/utils.d.ts +4 -4
- package/dist/src/impaktapps-ui-builder/lib/index.d.ts +1 -1
- package/package.json +1 -1
- package/src/impaktapps-ui-builder/builder/build/buildCard.ts +6 -6
- package/src/impaktapps-ui-builder/builder/build/buildFileInput.ts +1 -1
- package/src/impaktapps-ui-builder/builder/build/buildHorizontalBarGraph.ts +4 -0
- package/src/impaktapps-ui-builder/builder/build/buildPieGraph.ts +3 -1
- package/src/impaktapps-ui-builder/builder/build/buildProgressBar.ts +1 -1
- package/src/impaktapps-ui-builder/builder/build/buildRadio.ts +1 -1
- package/src/impaktapps-ui-builder/builder/build/buildSchema.ts +1 -1
- package/src/impaktapps-ui-builder/builder/build/buildStackBarGraph.ts +3 -0
- package/src/impaktapps-ui-builder/builder/build/buildTable.ts +23 -29
- package/src/impaktapps-ui-builder/builder/build/buildTextArea.ts +6 -0
- package/src/impaktapps-ui-builder/builder/build/buildUiSchema.ts +20 -12
- package/src/impaktapps-ui-builder/builder/build/buildUplaodFile.ts +16 -19
- package/src/impaktapps-ui-builder/builder/build/uischema/apiSection.ts +10 -10
- package/src/impaktapps-ui-builder/builder/build/uischema/buildPropertiesSection.ts +98 -50
- package/src/impaktapps-ui-builder/builder/build/uischema/button.ts +1 -1
- package/src/impaktapps-ui-builder/builder/build/uischema/card.ts +132 -90
- package/src/impaktapps-ui-builder/builder/build/uischema/coreSection.ts +11 -11
- package/src/impaktapps-ui-builder/builder/build/uischema/dateInputField.ts +3 -3
- package/src/impaktapps-ui-builder/builder/build/uischema/file.ts +2 -2
- package/src/impaktapps-ui-builder/builder/build/uischema/graph.ts +0 -1
- package/src/impaktapps-ui-builder/builder/build/uischema/leaderBoard.ts +6 -7
- package/src/impaktapps-ui-builder/builder/build/uischema/multiSelect.ts +1 -1
- package/src/impaktapps-ui-builder/builder/build/uischema/refresh.ts +3 -3
- package/src/impaktapps-ui-builder/builder/build/uischema/selectInputField.ts +1 -1
- package/src/impaktapps-ui-builder/builder/build/uischema/textInputField.ts +1 -1
- package/src/impaktapps-ui-builder/builder/build/uischema/validationSections.ts +3 -3
- package/src/impaktapps-ui-builder/builder/build/uischema/valueTab.ts +3 -3
- package/src/impaktapps-ui-builder/builder/elements/UiSchema/Component/schema.ts +32 -1
- package/src/impaktapps-ui-builder/builder/elements/UiSchema/Component/uiSchema.ts +15 -31
- package/src/impaktapps-ui-builder/builder/elements/UiSchema/PageMaster/uiSchema.ts +18 -11
- package/src/impaktapps-ui-builder/builder/elements/UiSchema/event/uiSchema.ts +7 -16
- package/src/impaktapps-ui-builder/builder/services/component.ts +15 -22
- package/src/impaktapps-ui-builder/builder/services/event.ts +33 -7
- package/src/impaktapps-ui-builder/builder/services/pageMaster.ts +12 -12
- package/src/impaktapps-ui-builder/builder/services/utils.ts +12 -12
- package/src/impaktapps-ui-builder/lib/index.ts +1 -1
- package/src/impaktapps-ui-builder/runtime/services/events.ts +4 -5
- package/src/impaktapps-ui-builder/runtime/services/service.ts +15 -16
- package/dist/src/impaktapps-ui-builder/builder/build/uischema/lazyLoadingTable.d.ts +0 -15
- package/src/impaktapps-ui-builder/builder/build/uischema/lazyLoadingTable.ts +0 -15
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const buildCard: (config: any, componentScope: any) => any;
|
|
1
|
+
export declare const buildCard: (config: any, componentScope: any, store: any) => any;
|
|
@@ -8,5 +8,5 @@ export declare const buildSchema: (config: any, tableName?: string, isArrayType?
|
|
|
8
8
|
properties: {};
|
|
9
9
|
required: any[];
|
|
10
10
|
};
|
|
11
|
-
declare const buildUiSchema: (config: any) => any;
|
|
11
|
+
declare const buildUiSchema: (config: any, store?: any) => any;
|
|
12
12
|
export default buildUiSchema;
|
|
@@ -27,6 +27,8 @@ export declare const buildWrapper: (label: string, elements: any[]) => {
|
|
|
27
27
|
wrapperStyle: {
|
|
28
28
|
marginTop: string;
|
|
29
29
|
marginBottom: string;
|
|
30
|
+
marginLeft: string;
|
|
31
|
+
width: string;
|
|
30
32
|
};
|
|
31
33
|
componentsBoxStyle: {
|
|
32
34
|
marginLeft: string;
|
|
@@ -57,6 +59,7 @@ export declare const getTextArea: (scope: string, heading: string, hideButton: b
|
|
|
57
59
|
heading: string;
|
|
58
60
|
minRows: number;
|
|
59
61
|
hideButton: boolean;
|
|
62
|
+
enableCodeEditor: boolean;
|
|
60
63
|
};
|
|
61
64
|
};
|
|
62
65
|
};
|
|
@@ -82,6 +85,26 @@ export declare const getSelectField: (scope: string, label: string, options: {
|
|
|
82
85
|
};
|
|
83
86
|
};
|
|
84
87
|
};
|
|
88
|
+
export declare const getMultiSelectField: (scope: string, label: string) => {
|
|
89
|
+
type: string;
|
|
90
|
+
scope: string;
|
|
91
|
+
options: {
|
|
92
|
+
widget: string;
|
|
93
|
+
};
|
|
94
|
+
config: {
|
|
95
|
+
layout: {
|
|
96
|
+
xs: number;
|
|
97
|
+
sm: number;
|
|
98
|
+
md: number;
|
|
99
|
+
lg: number;
|
|
100
|
+
};
|
|
101
|
+
main: {
|
|
102
|
+
multiple: boolean;
|
|
103
|
+
label: string;
|
|
104
|
+
options: any[];
|
|
105
|
+
};
|
|
106
|
+
};
|
|
107
|
+
};
|
|
85
108
|
export declare const buildPropertiesSection: (type: String) => {
|
|
86
109
|
type: string;
|
|
87
110
|
elements: any[];
|
|
@@ -1,20 +1,23 @@
|
|
|
1
|
-
|
|
1
|
+
export default function Card(theme: any): {
|
|
2
2
|
type: string;
|
|
3
3
|
config: {
|
|
4
|
-
main: {
|
|
5
|
-
|
|
6
|
-
};
|
|
4
|
+
main: {};
|
|
5
|
+
wrapperStyle: {};
|
|
7
6
|
componentsBoxStyle: {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
height: {
|
|
11
|
-
xs: string;
|
|
12
|
-
md: string;
|
|
13
|
-
};
|
|
7
|
+
flexDirection: string;
|
|
8
|
+
flexWrap: string;
|
|
14
9
|
width: string;
|
|
15
|
-
textAlign: string;
|
|
16
10
|
background: string;
|
|
11
|
+
border: string;
|
|
17
12
|
borderRadius: string;
|
|
13
|
+
padding: string;
|
|
14
|
+
"&: hover": {
|
|
15
|
+
background: string;
|
|
16
|
+
border: string;
|
|
17
|
+
"& p": {
|
|
18
|
+
color: string;
|
|
19
|
+
};
|
|
20
|
+
};
|
|
18
21
|
};
|
|
19
22
|
layout: {
|
|
20
23
|
xs: number;
|
|
@@ -25,94 +28,112 @@ declare const _default: {
|
|
|
25
28
|
};
|
|
26
29
|
elements: ({
|
|
27
30
|
type: string;
|
|
28
|
-
scope: string;
|
|
29
31
|
config: {
|
|
30
|
-
main: {
|
|
31
|
-
heading: string;
|
|
32
|
-
url?: undefined;
|
|
33
|
-
};
|
|
34
|
-
style: {
|
|
35
|
-
position: string;
|
|
36
|
-
left: string;
|
|
37
|
-
top: string;
|
|
38
|
-
color: string;
|
|
39
|
-
height: string;
|
|
40
|
-
display: string;
|
|
41
|
-
fontSize: {
|
|
42
|
-
xs: string;
|
|
43
|
-
md: string;
|
|
44
|
-
};
|
|
45
|
-
alignItems: string;
|
|
46
|
-
background: string;
|
|
47
|
-
justifyContent: string;
|
|
48
|
-
objectFit?: undefined;
|
|
49
|
-
right?: undefined;
|
|
50
|
-
width?: undefined;
|
|
51
|
-
padding?: undefined;
|
|
52
|
-
};
|
|
53
32
|
layout: number;
|
|
33
|
+
main?: undefined;
|
|
34
|
+
style?: undefined;
|
|
54
35
|
};
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
fontSize: string;
|
|
76
|
-
alignItems: string;
|
|
77
|
-
background: string;
|
|
78
|
-
padding: string;
|
|
79
|
-
justifyContent: string;
|
|
80
|
-
left?: undefined;
|
|
36
|
+
elements: {
|
|
37
|
+
type: string;
|
|
38
|
+
config: {
|
|
39
|
+
main: {
|
|
40
|
+
columnSpacing: number;
|
|
41
|
+
gap: number;
|
|
42
|
+
};
|
|
43
|
+
wrapperStyle: {
|
|
44
|
+
marginTop: string;
|
|
45
|
+
background: string;
|
|
46
|
+
};
|
|
47
|
+
componentsBoxStyle: {
|
|
48
|
+
flexDirection: string;
|
|
49
|
+
flexWrap: string;
|
|
50
|
+
width: string;
|
|
51
|
+
height: string;
|
|
52
|
+
background: string;
|
|
53
|
+
borderRadius: string;
|
|
54
|
+
};
|
|
55
|
+
layout: number;
|
|
81
56
|
};
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
57
|
+
elements: ({
|
|
58
|
+
type: string;
|
|
59
|
+
scope: string;
|
|
60
|
+
config: {
|
|
61
|
+
main: {
|
|
62
|
+
heading: string;
|
|
63
|
+
};
|
|
64
|
+
style: {
|
|
65
|
+
color: string;
|
|
66
|
+
display: string;
|
|
67
|
+
fontSize: {
|
|
68
|
+
xs: string;
|
|
69
|
+
md: string;
|
|
70
|
+
};
|
|
71
|
+
fontWeight: string;
|
|
72
|
+
background: string;
|
|
73
|
+
justifyContent: string;
|
|
74
|
+
width: string;
|
|
75
|
+
margin: string;
|
|
76
|
+
textWrap?: undefined;
|
|
77
|
+
lineHeight?: undefined;
|
|
78
|
+
};
|
|
79
|
+
layout: number;
|
|
80
|
+
};
|
|
81
|
+
options: {
|
|
82
|
+
widget: string;
|
|
83
|
+
};
|
|
84
|
+
} | {
|
|
85
|
+
type: string;
|
|
86
|
+
scope: string;
|
|
87
|
+
config: {
|
|
88
|
+
main: {
|
|
89
|
+
heading: string;
|
|
90
|
+
};
|
|
91
|
+
style: {
|
|
92
|
+
color: string;
|
|
93
|
+
fontSize: string;
|
|
94
|
+
justifyContent: string;
|
|
95
|
+
textWrap: string;
|
|
96
|
+
background: string;
|
|
97
|
+
width: string;
|
|
98
|
+
margin: string;
|
|
99
|
+
lineHeight: string;
|
|
100
|
+
display?: undefined;
|
|
101
|
+
fontWeight?: undefined;
|
|
102
|
+
};
|
|
103
|
+
layout: number;
|
|
104
|
+
};
|
|
105
|
+
options: {
|
|
106
|
+
widget: string;
|
|
107
|
+
};
|
|
108
|
+
})[];
|
|
109
|
+
}[];
|
|
110
|
+
scope?: undefined;
|
|
111
|
+
options?: undefined;
|
|
87
112
|
} | {
|
|
88
113
|
type: string;
|
|
89
114
|
scope: string;
|
|
90
115
|
config: {
|
|
91
116
|
main: {
|
|
92
|
-
|
|
93
|
-
url?: undefined;
|
|
117
|
+
url: string;
|
|
94
118
|
};
|
|
95
119
|
style: {
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
right?: undefined;
|
|
108
|
-
width?: undefined;
|
|
109
|
-
padding?: undefined;
|
|
120
|
+
containerStyle: {
|
|
121
|
+
height: string;
|
|
122
|
+
display: string;
|
|
123
|
+
justifyContent: string;
|
|
124
|
+
};
|
|
125
|
+
imageStyle: {
|
|
126
|
+
height: string;
|
|
127
|
+
fontSize: string;
|
|
128
|
+
padding: string;
|
|
129
|
+
marginLeft: string;
|
|
130
|
+
};
|
|
110
131
|
};
|
|
111
132
|
layout: number;
|
|
112
133
|
};
|
|
113
134
|
options: {
|
|
114
135
|
widget: string;
|
|
115
136
|
};
|
|
137
|
+
elements?: undefined;
|
|
116
138
|
})[];
|
|
117
139
|
};
|
|
118
|
-
export default _default;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
declare const
|
|
2
|
-
export default
|
|
1
|
+
declare const clearFromSessionStorage: () => void;
|
|
2
|
+
export default clearFromSessionStorage;
|
|
3
3
|
export declare const getNavigationHistory: (config: any, path: string | undefined) => {
|
|
4
4
|
pageName: string;
|
|
5
5
|
};
|
|
6
|
-
export declare const
|
|
7
|
-
export declare const
|
|
6
|
+
export declare const saveFormdataInSessionStorage: (formData: any, path?: string) => any;
|
|
7
|
+
export declare const getFormdataFromSessionStorage: (path?: string) => any;
|
|
8
8
|
export declare function saveHandler(store: any, service: any, submitHandler: any, pageName?: string): Promise<void>;
|
|
9
9
|
export declare const navigateHandler: (store: any, isSubmitted: any, pageName?: string | boolean) => void;
|
|
10
10
|
export declare function okHandler(store: any): void;
|
|
@@ -6,4 +6,4 @@ export { schema } from "../builder/build/buildUiSchema";
|
|
|
6
6
|
export { default as buildConfig } from "../builder/build/buildConfig";
|
|
7
7
|
export { default as buildUiSchema } from "../builder/build/buildUiSchema";
|
|
8
8
|
export { buildSchema } from "../builder/build/buildUiSchema";
|
|
9
|
-
export { default as
|
|
9
|
+
export { default as clearFromSessionStorage } from "../builder/services/utils";
|
package/package.json
CHANGED
|
@@ -2,25 +2,25 @@ import Card from "./uischema/card";
|
|
|
2
2
|
import _ from "lodash";
|
|
3
3
|
import { createLayoutFormat } from "./buildConfig";
|
|
4
4
|
|
|
5
|
-
export const buildCard = (config,componentScope) =>{
|
|
6
|
-
const card: any = _.cloneDeep(Card);
|
|
5
|
+
export const buildCard = (config,componentScope,store) =>{
|
|
6
|
+
const card: any = _.cloneDeep(Card(store.theme.myTheme));
|
|
7
7
|
if (config.style) {
|
|
8
8
|
card.config.style = JSON.parse(config.style)
|
|
9
9
|
}
|
|
10
|
-
card.elements[0].scope = `#/properties/${config.name}/properties/value`
|
|
10
|
+
card.elements[0].elements[0].elements[0].scope = `#/properties/${config.name}/properties/value`
|
|
11
11
|
card.elements[1].scope = `#/properties/${config.name}/properties/url`
|
|
12
|
-
card.elements[
|
|
12
|
+
card.elements[0].elements[0].elements[1].scope = `#/properties/${config.name}/properties/description`
|
|
13
13
|
if(config.layout){
|
|
14
14
|
card.config.layout = createLayoutFormat(config.layout)
|
|
15
15
|
}
|
|
16
16
|
if(config.label){
|
|
17
|
-
card.elements[0].config.main.heading = config.label;
|
|
17
|
+
card.elements[0].elements[0].elements[0].config.main.heading = config.label;
|
|
18
18
|
}
|
|
19
19
|
if(config.url){
|
|
20
20
|
card.elements[1].config.main.url = config.url;
|
|
21
21
|
}
|
|
22
22
|
if(config.description){
|
|
23
|
-
card.elements[
|
|
23
|
+
card.elements[0].elements[0].elements[1].config.main.heading = config.description;
|
|
24
24
|
}
|
|
25
25
|
|
|
26
26
|
|
|
@@ -9,11 +9,15 @@ const buildHorizontalBarGraph = (config:any,componentScope:string) => {
|
|
|
9
9
|
if (config.layout) {
|
|
10
10
|
horizontalBarGraph.config.layout = createLayoutFormat(config.layout);
|
|
11
11
|
}
|
|
12
|
+
horizontalBarGraph.config.main.type = config.graphType;
|
|
12
13
|
horizontalBarGraph.scope = componentScope;
|
|
13
14
|
horizontalBarGraph.config.main.header = config.heading;
|
|
14
15
|
if (config.barColor) {
|
|
15
16
|
horizontalBarGraph.config.barStyle.color = config.barColor;
|
|
16
17
|
}
|
|
18
|
+
if (config.xAxisValue) {
|
|
19
|
+
horizontalBarGraph.config.main.xAxisValue = config.xAxisValue;
|
|
20
|
+
}
|
|
17
21
|
if (config.containerBackground) {
|
|
18
22
|
horizontalBarGraph.config.containerStyle.background =
|
|
19
23
|
config.containerBackground;
|
|
@@ -24,7 +24,9 @@ export const buildPieGraph = (config, componentScope) => {
|
|
|
24
24
|
if (config.legendLabels) {
|
|
25
25
|
pieGraph.config.main.tooltipDataKey = flatObjectValueInArray(config.legendLabels);
|
|
26
26
|
}
|
|
27
|
-
|
|
27
|
+
if (config.xAxisValue) {
|
|
28
|
+
pieGraph.config.main.xAxisValue = config.xAxisValue;
|
|
29
|
+
}
|
|
28
30
|
if (config.pieArcColors) {
|
|
29
31
|
pieGraph.config.style = {
|
|
30
32
|
pieStyle: {
|
|
@@ -8,7 +8,7 @@ export const buildProgressBar = (config:any,componentScope:any) =>{
|
|
|
8
8
|
if (config.layout) {
|
|
9
9
|
ProgressBar.config.layout = config.layout;
|
|
10
10
|
}
|
|
11
|
-
ProgressBar.config.main.heading = config.
|
|
11
|
+
ProgressBar.config.main.heading = config.label;
|
|
12
12
|
if (config.bottomLabel_3) {
|
|
13
13
|
ProgressBar.config.main.bottomLabel_3 = config.bottomLabel_3;
|
|
14
14
|
}
|
|
@@ -25,7 +25,7 @@ export const buildSchema = (config: any) => {
|
|
|
25
25
|
|
|
26
26
|
}
|
|
27
27
|
buildRule(config)
|
|
28
|
-
window.
|
|
28
|
+
window.sessionStorage.setItem("schemaDemo",JSON.stringify(schema))
|
|
29
29
|
return schema;
|
|
30
30
|
};
|
|
31
31
|
export default buildSchema;
|
|
@@ -15,6 +15,9 @@ export const buildStackbarGraph = (config:any,componentScope:string) => {
|
|
|
15
15
|
if (config.barColor) {
|
|
16
16
|
barGraph.config.barStyle.color = config.barColor;
|
|
17
17
|
}
|
|
18
|
+
if (config.xAxisValue) {
|
|
19
|
+
barGraph.config.main.xAxisValue = config.xAxisValue;
|
|
20
|
+
}
|
|
18
21
|
if (config.height) {
|
|
19
22
|
barGraph.config.style.containerStyle.height = config.height;
|
|
20
23
|
}
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import Table from "./uischema/table";
|
|
2
2
|
import _ from "lodash";
|
|
3
|
-
import buildUiSchema from "./buildUiSchema";
|
|
4
|
-
import lazyLoadingTable from "./uischema/lazyLoadingTable";
|
|
5
3
|
|
|
6
4
|
export const buildTable = (config: any, componentScope: string) => {
|
|
7
5
|
const table: any = _.cloneDeep(Table);
|
|
@@ -40,39 +38,35 @@ export const buildTable = (config: any, componentScope: string) => {
|
|
|
40
38
|
if (config.downloadAllData) {
|
|
41
39
|
table.config.main.downloadAllData = config.downloadAllData === "YES" ? true : false
|
|
42
40
|
}
|
|
43
|
-
if
|
|
44
|
-
table.config.main.
|
|
41
|
+
if(config.disableGlobalSearch){
|
|
42
|
+
table.config.main.disableGlobalSearch = config.disableGlobalSearch === "YES" ? true : false
|
|
45
43
|
}
|
|
46
|
-
if
|
|
47
|
-
table.config.main.
|
|
44
|
+
if(config.disableColumnFilter){
|
|
45
|
+
table.config.main.disableColumnFilter = config.disableColumnFilter === "YES" ? true : false
|
|
48
46
|
}
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
export const buildLazyLoadingTable = (config: any, componentScope: string) => {
|
|
53
|
-
const table: any = _.cloneDeep(lazyLoadingTable);
|
|
54
|
-
table.scope = componentScope;
|
|
55
|
-
if (config.style) {
|
|
56
|
-
table.config.style = JSON.parse(config.style)
|
|
47
|
+
if(config.disableSorting){
|
|
48
|
+
table.config.main.disableSorting = config.disableSorting === "YES" ? true : false
|
|
57
49
|
}
|
|
58
|
-
if
|
|
59
|
-
table.config.main.
|
|
60
|
-
};
|
|
61
|
-
if (config.ColumnResizingAvailable) {
|
|
62
|
-
table.config.main.disableColumnResizing = config.ColumnResizingAvailable === "YES" ? false : true
|
|
63
|
-
};
|
|
64
|
-
if (config.DragAvailable) {
|
|
65
|
-
table.config.main.enableDrag = config.DragAvailable === "YES" ? true : false
|
|
66
|
-
};
|
|
67
|
-
if (config.selectKey) {
|
|
68
|
-
table.config.main.selectKey = config.selectKey
|
|
50
|
+
if(config.disableEditColumn){
|
|
51
|
+
table.config.main.disableEditColumn = config.disableEditColumn === "YES" ? true : false
|
|
69
52
|
}
|
|
70
|
-
if
|
|
71
|
-
table.config.main.
|
|
53
|
+
if(config.disableFullScreenToggle){
|
|
54
|
+
table.config.main.disableFullScreenToggle = config.disableFullScreenToggle === "YES" ? true : false
|
|
55
|
+
}
|
|
56
|
+
if(config.disableDensityToggle){
|
|
57
|
+
table.config.main.disableDensityToggle = config.disableDensityToggle === "YES" ? true : false
|
|
58
|
+
}
|
|
59
|
+
if(config.disableDownloadFile){
|
|
60
|
+
table.config.main.disableDownloadFile = config.disableDownloadFile === "YES" ? true : false
|
|
61
|
+
}
|
|
62
|
+
if(config.disablePagination){
|
|
63
|
+
table.config.main.disablePagination = config.disablePagination === "YES" ? true : false
|
|
72
64
|
}
|
|
73
65
|
if (config.Table_Download_Keys_Name) {
|
|
74
66
|
table.config.main.TableDownloadKeysName = config.Table_Download_Keys_Name.map(e => e.KeyName);
|
|
75
67
|
}
|
|
76
|
-
|
|
68
|
+
if (config.selectKey) {
|
|
69
|
+
table.config.main.selectKey = config.selectKey
|
|
70
|
+
}
|
|
77
71
|
return table;
|
|
78
|
-
}
|
|
72
|
+
};
|
|
@@ -45,6 +45,12 @@ export const buildTextArea = (config:any,componentScope:string) =>{
|
|
|
45
45
|
if (config.placeholder) {
|
|
46
46
|
textArea.config.main.placeholder = config.placeholder;
|
|
47
47
|
}
|
|
48
|
+
if(config.enableCodeEditor){
|
|
49
|
+
textArea.config.main.enableCodeEditor = config.enableCodeEditor === "YES" ? true : false
|
|
50
|
+
}
|
|
51
|
+
if(config.codeEditorLanguage){
|
|
52
|
+
textArea.config.main.codeEditorLanguage = config.codeEditorLanguage;
|
|
53
|
+
}
|
|
48
54
|
textArea.scope = componentScope;
|
|
49
55
|
return textArea;
|
|
50
56
|
}
|
|
@@ -14,7 +14,7 @@ import { buildWrapperSection } from "./buildWrapperSection";
|
|
|
14
14
|
import { buildTextField } from "./buildText";
|
|
15
15
|
import { buildSelect } from "./buildSelect";
|
|
16
16
|
import { buildButton } from "./buildButton";
|
|
17
|
-
import {
|
|
17
|
+
import { buildTable } from "./buildTable";
|
|
18
18
|
import { buildLabel } from "./buildLabel";
|
|
19
19
|
import { buildUploadFile } from "./buildUplaodFile";
|
|
20
20
|
import { buildDownloadFile } from "./buildDownloadFile";
|
|
@@ -165,7 +165,7 @@ export const buildSchema = (config: any, tableName?: string, isArrayType?: boole
|
|
|
165
165
|
}
|
|
166
166
|
|
|
167
167
|
|
|
168
|
-
const buildUiSchema = (config: any) => {
|
|
168
|
+
const buildUiSchema = (config: any, store?: any) => {
|
|
169
169
|
let elements: any = {};
|
|
170
170
|
const componentScope = `#/properties/${config.name}`;
|
|
171
171
|
switch (config.type) {
|
|
@@ -230,9 +230,6 @@ const buildUiSchema = (config: any) => {
|
|
|
230
230
|
case "Array":
|
|
231
231
|
elements = buildArray(config, componentScope);
|
|
232
232
|
break;
|
|
233
|
-
case "LazyLoadingTable":
|
|
234
|
-
elements = buildLazyLoadingTable(config, componentScope)
|
|
235
|
-
break;
|
|
236
233
|
case "Box":
|
|
237
234
|
elements = buildLabel(config, componentScope);
|
|
238
235
|
break;
|
|
@@ -249,7 +246,7 @@ const buildUiSchema = (config: any) => {
|
|
|
249
246
|
elements = buildEmptyBox(config, componentScope);
|
|
250
247
|
break;
|
|
251
248
|
case "card":
|
|
252
|
-
elements = buildCard(config, componentScope);
|
|
249
|
+
elements = buildCard(config, componentScope, store);
|
|
253
250
|
break;
|
|
254
251
|
case "Graph":
|
|
255
252
|
switch (config.graphType) {
|
|
@@ -264,6 +261,7 @@ const buildUiSchema = (config: any) => {
|
|
|
264
261
|
elements = buildPieGraph(config, componentScope);
|
|
265
262
|
break;
|
|
266
263
|
case "HorizontalBarGraph":
|
|
264
|
+
case "HorizontalStackBarGraph":
|
|
267
265
|
elements = buildHorizontalBarGraph(config, componentScope);
|
|
268
266
|
break;
|
|
269
267
|
}
|
|
@@ -328,17 +326,23 @@ const buildUiSchema = (config: any) => {
|
|
|
328
326
|
header: cellElem.label || cellElem.name,
|
|
329
327
|
size: sizeMap[cellElem.name] || 180,
|
|
330
328
|
type: cellElem.columnFormat,
|
|
331
|
-
elements: cellElem.type == "ColumnGroup" ? cellElem.elements.map((childCellElem) => buildUiSchema(childCellElem)) : []
|
|
329
|
+
elements: cellElem.type == "ColumnGroup" ? cellElem.elements.map((childCellElem) => buildUiSchema(childCellElem, store)) : []
|
|
332
330
|
}
|
|
333
331
|
})
|
|
334
332
|
}
|
|
335
333
|
else if (config.type == "Table") {
|
|
336
334
|
const sizeMap = {}
|
|
335
|
+
const filterMap = {}
|
|
337
336
|
if (config.sizeHolder) {
|
|
338
337
|
config.sizeHolder.map((e, i) => {
|
|
339
338
|
sizeMap[e.keyName] = e.value
|
|
340
339
|
});
|
|
341
340
|
}
|
|
341
|
+
if(config.enableColumnFilter){
|
|
342
|
+
config.enableColumnFilter.map((e)=>{
|
|
343
|
+
filterMap[e.keyName] = true
|
|
344
|
+
})
|
|
345
|
+
}
|
|
342
346
|
elements.elements = config.elements.map((cellElem, elemInd) => {
|
|
343
347
|
if (cellElem.type) {
|
|
344
348
|
return {
|
|
@@ -346,15 +350,19 @@ const buildUiSchema = (config: any) => {
|
|
|
346
350
|
header: cellElem.label || cellElem.name,
|
|
347
351
|
size: sizeMap[cellElem.name] || 180,
|
|
348
352
|
type: cellElem.columnFormat,
|
|
349
|
-
widget: cellElem.type != "ColumnGroup" ? buildUiSchema(cellElem) : undefined,
|
|
350
|
-
elements: cellElem.type == "ColumnGroup" ? cellElem.elements.map((childCellElem) => buildUiSchema(childCellElem)) : []
|
|
353
|
+
widget: cellElem.type != "ColumnGroup" ? buildUiSchema(cellElem, store) : undefined,
|
|
354
|
+
elements: cellElem.type == "ColumnGroup" ? cellElem.elements.map((childCellElem) => buildUiSchema(childCellElem, store)) : [],
|
|
355
|
+
enableColumnFilter: Object.keys(filterMap).length === 0 ? true : filterMap[cellElem.name] ?? false,
|
|
356
|
+
columnFilterModeOptions: config.filteringOptions
|
|
351
357
|
}
|
|
352
358
|
} else {
|
|
353
359
|
return {
|
|
354
360
|
accessorKey: cellElem.name,
|
|
355
361
|
type: cellElem.columnFormat,
|
|
356
362
|
header: cellElem.label || cellElem.name,
|
|
357
|
-
size: sizeMap[cellElem.name] || 180
|
|
363
|
+
size: sizeMap[cellElem.name] || 180,
|
|
364
|
+
enableColumnFilter: Object.keys(filterMap).length === 0 ? true : filterMap[cellElem.name] ?? false,
|
|
365
|
+
columnFilterModeOptions: config.filteringOptions
|
|
358
366
|
}
|
|
359
367
|
}
|
|
360
368
|
|
|
@@ -362,12 +370,12 @@ const buildUiSchema = (config: any) => {
|
|
|
362
370
|
}
|
|
363
371
|
else if (config.type == "Array") {
|
|
364
372
|
elements.options.detail.elements = config.elements.map((e: any, elemInd: number) => {
|
|
365
|
-
return buildUiSchema(e)
|
|
373
|
+
return buildUiSchema(e,store)
|
|
366
374
|
});
|
|
367
375
|
}
|
|
368
376
|
else {
|
|
369
377
|
elements.elements = config.elements.map((e: any, elemInd: number) => {
|
|
370
|
-
return buildUiSchema(e)
|
|
378
|
+
return buildUiSchema(e,store)
|
|
371
379
|
});
|
|
372
380
|
}
|
|
373
381
|
}
|