impaktapps-ui-builder 0.0.342 → 0.0.344
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 +24 -22
- package/dist/impaktapps-ui-builder.es.js.map +1 -1
- package/dist/impaktapps-ui-builder.umd.js +7 -7
- package/dist/impaktapps-ui-builder.umd.js.map +1 -1
- package/dist/src/impaktapps-ui-builder/builder/services/component.d.ts +8 -8
- package/dist/src/impaktapps-ui-builder/builder/services/event.d.ts +8 -8
- package/dist/src/impaktapps-ui-builder/builder/services/pageMaster.d.ts +8 -8
- package/package.json +1 -1
- package/src/impaktapps-ui-builder/builder/services/component.ts +10 -9
- package/src/impaktapps-ui-builder/builder/services/event.ts +6 -5
- package/src/impaktapps-ui-builder/builder/services/pageMaster.ts +6 -6
|
@@ -2,17 +2,17 @@ export declare const refreshPage: (type: string, store: any) => void;
|
|
|
2
2
|
declare const _default: (store: any, dynamicData: any, submitHandler: any, service: any) => {
|
|
3
3
|
setPage: () => Promise<void>;
|
|
4
4
|
refreshPage: (type: string, store: any) => void;
|
|
5
|
-
getFormdata: () =>
|
|
5
|
+
getFormdata: () => any;
|
|
6
6
|
getSchema: () => any;
|
|
7
|
-
okHandler: () =>
|
|
7
|
+
okHandler: () => void;
|
|
8
8
|
savePageHandler: () => Promise<void>;
|
|
9
9
|
onChange: () => void;
|
|
10
|
-
editComponents: () =>
|
|
11
|
-
deleteComponents: () =>
|
|
12
|
-
deleteEvent: () =>
|
|
13
|
-
widgetAddClickHandler: () =>
|
|
14
|
-
eventEditHandler: () =>
|
|
15
|
-
eventAddHandler: () =>
|
|
10
|
+
editComponents: () => void;
|
|
11
|
+
deleteComponents: () => void;
|
|
12
|
+
deleteEvent: () => void;
|
|
13
|
+
widgetAddClickHandler: () => void;
|
|
14
|
+
eventEditHandler: () => void;
|
|
15
|
+
eventAddHandler: () => void;
|
|
16
16
|
backHandler: () => void;
|
|
17
17
|
};
|
|
18
18
|
export default _default;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
declare const _default: (store: any, dynamicData: any, submitHandler: any, service: any) => {
|
|
2
2
|
setPage: () => Promise<void>;
|
|
3
3
|
refreshPage: (handlerType: any, store: any) => void;
|
|
4
|
-
getFormData: () =>
|
|
5
|
-
getUiSchema: () =>
|
|
6
|
-
getSchema: () =>
|
|
4
|
+
getFormData: () => any;
|
|
5
|
+
getUiSchema: () => any;
|
|
6
|
+
getSchema: () => {
|
|
7
7
|
type: string;
|
|
8
8
|
properties: {
|
|
9
9
|
headers: {
|
|
@@ -75,13 +75,13 @@ declare const _default: (store: any, dynamicData: any, submitHandler: any, servi
|
|
|
75
75
|
};
|
|
76
76
|
};
|
|
77
77
|
required: string[];
|
|
78
|
-
}
|
|
78
|
+
};
|
|
79
79
|
savePageHandler: () => Promise<void>;
|
|
80
80
|
onChange: () => void;
|
|
81
|
-
okHandler: () =>
|
|
82
|
-
addEvent: () =>
|
|
83
|
-
editEvent: () =>
|
|
84
|
-
deleteEvent: () =>
|
|
81
|
+
okHandler: () => void;
|
|
82
|
+
addEvent: () => void;
|
|
83
|
+
editEvent: () => void;
|
|
84
|
+
deleteEvent: () => void;
|
|
85
85
|
backHandler: () => void;
|
|
86
86
|
};
|
|
87
87
|
export default _default;
|
|
@@ -8,8 +8,8 @@ interface funcParamsProps {
|
|
|
8
8
|
}
|
|
9
9
|
declare const _default: (funcParams: funcParamsProps) => {
|
|
10
10
|
setPage: () => Promise<void>;
|
|
11
|
-
getFormdata: () =>
|
|
12
|
-
getUiSchema: () =>
|
|
11
|
+
getFormdata: () => any;
|
|
12
|
+
getUiSchema: () => any;
|
|
13
13
|
getSchema: () => {
|
|
14
14
|
type: string;
|
|
15
15
|
properties: {
|
|
@@ -49,12 +49,12 @@ declare const _default: (funcParams: funcParamsProps) => {
|
|
|
49
49
|
required: string[];
|
|
50
50
|
};
|
|
51
51
|
backHandler: () => void;
|
|
52
|
-
onAddClickHandler: () =>
|
|
52
|
+
onAddClickHandler: () => void;
|
|
53
53
|
savePageHandler: () => Promise<void>;
|
|
54
|
-
Edit_Components: () =>
|
|
55
|
-
Delete_Components: () =>
|
|
56
|
-
eventAddHandler: () =>
|
|
57
|
-
editEvent: () =>
|
|
58
|
-
deleteEvent: () =>
|
|
54
|
+
Edit_Components: () => void;
|
|
55
|
+
Delete_Components: () => void;
|
|
56
|
+
eventAddHandler: () => void;
|
|
57
|
+
editEvent: () => void;
|
|
58
|
+
deleteEvent: () => void;
|
|
59
59
|
};
|
|
60
60
|
export default _default;
|
package/package.json
CHANGED
|
@@ -70,14 +70,14 @@ export default (store: any, dynamicData: any, submitHandler: any, service: any)
|
|
|
70
70
|
|
|
71
71
|
},
|
|
72
72
|
refreshPage:refreshPage,
|
|
73
|
-
getFormdata:
|
|
73
|
+
getFormdata: function () {
|
|
74
74
|
const path = store.searchParams?.get("path");
|
|
75
75
|
return getFormdataFromLocalStorage(path)
|
|
76
76
|
},
|
|
77
77
|
getSchema: function () {
|
|
78
78
|
return ComponentSchema;
|
|
79
79
|
},
|
|
80
|
-
okHandler:
|
|
80
|
+
okHandler: function () {
|
|
81
81
|
const path = store.searchParams?.get("path");
|
|
82
82
|
console.log(store.ctx.core.errors)
|
|
83
83
|
if (_.isEmpty(store.ctx.core.errors)) {
|
|
@@ -97,7 +97,8 @@ export default (store: any, dynamicData: any, submitHandler: any, service: any)
|
|
|
97
97
|
},
|
|
98
98
|
savePageHandler: async () => {
|
|
99
99
|
const id = store.searchParams?.get("id");
|
|
100
|
-
|
|
100
|
+
const path = store.searchParams?.get("path");
|
|
101
|
+
saveFormdataInLocalStorage(store.ctx.core.data, path);
|
|
101
102
|
const config = localStorage.getItem("pageFormdata");
|
|
102
103
|
const isSubmitted = await saveHandler(store, service, submitHandler,config);
|
|
103
104
|
if (isSubmitted) {
|
|
@@ -124,7 +125,7 @@ export default (store: any, dynamicData: any, submitHandler: any, service: any)
|
|
|
124
125
|
this.refreshPage(store?.newData?.type,store);
|
|
125
126
|
}
|
|
126
127
|
},
|
|
127
|
-
editComponents:
|
|
128
|
+
editComponents: function () {
|
|
128
129
|
const rowId = dynamicData.path.split(".")[1];
|
|
129
130
|
const path = store.searchParams?.get("path");
|
|
130
131
|
const id = store.searchParams?.get("id");
|
|
@@ -139,7 +140,7 @@ export default (store: any, dynamicData: any, submitHandler: any, service: any)
|
|
|
139
140
|
store.navigate(`/Component?path=${`elements[${rowId}]`}&id=${id}`)
|
|
140
141
|
}
|
|
141
142
|
},
|
|
142
|
-
deleteComponents:
|
|
143
|
+
deleteComponents: function () {
|
|
143
144
|
const path = store.searchParams?.get("path");
|
|
144
145
|
const rowId = dynamicData.path.split(".")[1];
|
|
145
146
|
store.formData.elements.splice(rowId, 1);
|
|
@@ -147,14 +148,14 @@ export default (store: any, dynamicData: any, submitHandler: any, service: any)
|
|
|
147
148
|
const data = path ? _.get(response, path) : response;
|
|
148
149
|
store.setFormdata(data);
|
|
149
150
|
},
|
|
150
|
-
deleteEvent:
|
|
151
|
+
deleteEvent: function () {
|
|
151
152
|
const path = store.searchParams?.get("path");
|
|
152
153
|
const rowId = dynamicData.path.split(".")[1];
|
|
153
154
|
store.formData.events.splice(rowId, 1);
|
|
154
155
|
const response = saveFormdataInLocalStorage(store.ctx.core.data, path)
|
|
155
156
|
store.setFormdata(_.get(response, path));
|
|
156
157
|
},
|
|
157
|
-
widgetAddClickHandler:
|
|
158
|
+
widgetAddClickHandler: function () {
|
|
158
159
|
if (!Array.isArray(store.formData.elements)) {
|
|
159
160
|
store.formData.elements = []
|
|
160
161
|
}
|
|
@@ -166,7 +167,7 @@ export default (store: any, dynamicData: any, submitHandler: any, service: any)
|
|
|
166
167
|
this.setPage()
|
|
167
168
|
|
|
168
169
|
},
|
|
169
|
-
eventEditHandler:
|
|
170
|
+
eventEditHandler: function () {
|
|
170
171
|
const rowId = dynamicData.path.split(".")[1];
|
|
171
172
|
const path = store.searchParams?.get("path");
|
|
172
173
|
const id = store.searchParams?.get("id");
|
|
@@ -174,7 +175,7 @@ export default (store: any, dynamicData: any, submitHandler: any, service: any)
|
|
|
174
175
|
const finalPath = `${path}.events[${rowId}]`
|
|
175
176
|
store.navigate(`/ComponentEvents?path=${finalPath}&id=${id}`)
|
|
176
177
|
},
|
|
177
|
-
eventAddHandler:
|
|
178
|
+
eventAddHandler: function () {
|
|
178
179
|
const path = store.searchParams?.get("path");
|
|
179
180
|
const id = store.searchParams?.get("id");
|
|
180
181
|
if (!Array.isArray(store.formData.events)) {
|
|
@@ -52,15 +52,16 @@ export default (
|
|
|
52
52
|
},
|
|
53
53
|
|
|
54
54
|
getFormData: Component(store, dynamicData,submitHandler,service).getFormdata,
|
|
55
|
-
getUiSchema:
|
|
55
|
+
getUiSchema: function () {
|
|
56
56
|
return EventUiSchema;
|
|
57
57
|
},
|
|
58
|
-
getSchema:
|
|
58
|
+
getSchema: () => {
|
|
59
59
|
return EventSchema;
|
|
60
60
|
},
|
|
61
61
|
savePageHandler: async () => {
|
|
62
62
|
const id = store.searchParams?.get("id");
|
|
63
|
-
|
|
63
|
+
const path = store.searchParams?.get("path");
|
|
64
|
+
saveFormdataInLocalStorage(store.ctx.core.data,path);
|
|
64
65
|
const config = localStorage.getItem("pageFormdata");
|
|
65
66
|
const isSubmitted = await saveHandler(store, service, submitHandler,config);
|
|
66
67
|
if (isSubmitted) {
|
|
@@ -89,7 +90,7 @@ export default (
|
|
|
89
90
|
},
|
|
90
91
|
|
|
91
92
|
okHandler: Component(store, dynamicData,submitHandler,service).okHandler,
|
|
92
|
-
addEvent:
|
|
93
|
+
addEvent: function () {
|
|
93
94
|
const path = store.searchParams?.get("path");
|
|
94
95
|
if (!Array.isArray(store.formData.events)) {
|
|
95
96
|
store.formData.events = []
|
|
@@ -100,7 +101,7 @@ export default (
|
|
|
100
101
|
store.setSearchParams(store.searchParams)
|
|
101
102
|
this.setPage()
|
|
102
103
|
},
|
|
103
|
-
editEvent:
|
|
104
|
+
editEvent: function () {
|
|
104
105
|
const rowId = dynamicData.path.split(".")[1];
|
|
105
106
|
const path = store.searchParams?.get("path");
|
|
106
107
|
saveFormdataInLocalStorage(store.ctx.core.data, path)
|
|
@@ -36,7 +36,7 @@ export default (funcParams: funcParamsProps) => {
|
|
|
36
36
|
store.setSchema(schema);
|
|
37
37
|
store.setUiSchema(uiSchema);
|
|
38
38
|
},
|
|
39
|
-
getFormdata:
|
|
39
|
+
getFormdata: function () {
|
|
40
40
|
const id = store.searchParams?.get("id");
|
|
41
41
|
const formData = getFormdataFromLocalStorage()
|
|
42
42
|
if (formData) {
|
|
@@ -45,7 +45,7 @@ export default (funcParams: funcParamsProps) => {
|
|
|
45
45
|
saveFormdataInLocalStorage(config)
|
|
46
46
|
return config
|
|
47
47
|
},
|
|
48
|
-
getUiSchema:
|
|
48
|
+
getUiSchema: function () {
|
|
49
49
|
return PageMasterUiSchema;
|
|
50
50
|
},
|
|
51
51
|
getSchema: () => {
|
|
@@ -55,7 +55,7 @@ export default (funcParams: funcParamsProps) => {
|
|
|
55
55
|
localStorage.removeItem("pageFormdata")
|
|
56
56
|
store.navigate("/PageMasterRecords");
|
|
57
57
|
},
|
|
58
|
-
onAddClickHandler:
|
|
58
|
+
onAddClickHandler: function () {
|
|
59
59
|
const id = store.searchParams?.get("id");
|
|
60
60
|
if (!Array.isArray(store.formData.elements)) {
|
|
61
61
|
store.formData.elements = []
|
|
@@ -86,7 +86,7 @@ export default (funcParams: funcParamsProps) => {
|
|
|
86
86
|
},
|
|
87
87
|
Edit_Components: Component(store, dynamicData, submitHandler, service).editComponents,
|
|
88
88
|
Delete_Components: Component(store, dynamicData, submitHandler, service).deleteComponents,
|
|
89
|
-
eventAddHandler:
|
|
89
|
+
eventAddHandler: function () {
|
|
90
90
|
const id = store.searchParams?.get("id");
|
|
91
91
|
if (!Array.isArray(store.formData.events)) {
|
|
92
92
|
store.formData.events = []
|
|
@@ -95,14 +95,14 @@ export default (funcParams: funcParamsProps) => {
|
|
|
95
95
|
const finalPath = `events[${store.formData.events.length}]`
|
|
96
96
|
store.navigate(`/ComponentEvents?path=${finalPath}&id=${id}`)
|
|
97
97
|
},
|
|
98
|
-
editEvent:
|
|
98
|
+
editEvent: function () {
|
|
99
99
|
const rowId = dynamicData.path.split(".")[1];
|
|
100
100
|
const id = store.searchParams?.get("id");
|
|
101
101
|
saveFormdataInLocalStorage(store.ctx.core.data)
|
|
102
102
|
const finalPath = `events[${rowId}]`
|
|
103
103
|
store.navigate(`/ComponentEvents?path=${finalPath}&id=${id}`)
|
|
104
104
|
},
|
|
105
|
-
deleteEvent:
|
|
105
|
+
deleteEvent: function () {
|
|
106
106
|
const rowId = dynamicData.path.split(".")[1];
|
|
107
107
|
store.formData.events.splice(rowId, 1);
|
|
108
108
|
const response = saveFormdataInLocalStorage(store.ctx.core.data)
|