@bolttech/form-engine-core 0.0.3-beta.7 → 0.0.3-beta.9
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/index.esm.js +6 -7
- package/package.json +1 -1
package/index.esm.js
CHANGED
|
@@ -72,11 +72,12 @@ function makeRequest(method, url, headers, body, queryParams) {
|
|
|
72
72
|
return new Promise(function (resolve, reject) {
|
|
73
73
|
const xhr = new XMLHttpRequest();
|
|
74
74
|
if (queryParams) {
|
|
75
|
-
const
|
|
75
|
+
const [baseUrl, existingParamsString] = url.split('?');
|
|
76
|
+
const searchParams = new URLSearchParams(existingParamsString);
|
|
76
77
|
Object.keys(queryParams).forEach(param => {
|
|
77
|
-
|
|
78
|
+
searchParams.append(param, queryParams[param]);
|
|
78
79
|
});
|
|
79
|
-
url =
|
|
80
|
+
url = `${baseUrl}?${searchParams.toString()}`;
|
|
80
81
|
}
|
|
81
82
|
xhr.open(method, url, true);
|
|
82
83
|
if (headers) {
|
|
@@ -3293,10 +3294,8 @@ class FormCore {
|
|
|
3293
3294
|
}
|
|
3294
3295
|
const fieldProp = field[property];
|
|
3295
3296
|
let propState;
|
|
3296
|
-
if (Array.isArray(fieldProp)) {
|
|
3297
|
-
propState =
|
|
3298
|
-
} else if (typeof fieldProp === 'object' && !isNil(fieldProp)) {
|
|
3299
|
-
propState = Object.assign({}, fieldProp);
|
|
3297
|
+
if (Array.isArray(fieldProp) || typeof fieldProp === 'object' && !isNil(fieldProp)) {
|
|
3298
|
+
propState = cloneDeep(fieldProp);
|
|
3300
3299
|
} else {
|
|
3301
3300
|
this.config.defaultLogVerbose && console.warn(`invalid template property, skipping evaluation of ${field.name} with ${fieldProp}`);
|
|
3302
3301
|
return;
|