@itrocks/core-transformers 0.1.3 → 0.1.4
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/cjs/collection-type.js +2 -2
- package/cjs/store.js +1 -1
- package/esm/collection-type.js +2 -2
- package/esm/store.js +1 -1
- package/package.json +1 -1
package/cjs/collection-type.js
CHANGED
|
@@ -35,15 +35,15 @@ async function collectionEdit(values, object, property) {
|
|
|
35
35
|
const attrValue = `value="${await depends.representativeValueOf(object)}"`;
|
|
36
36
|
const objectId = (0, storage_1.dataSource)().isObjectConnected(object) ? '' + object.id : '';
|
|
37
37
|
inputs.push('<li>'
|
|
38
|
-
+ `<input name="${fieldName}.${objectId}" ${attrValue}>`
|
|
39
38
|
+ `<input id="${fieldId}-id.${objectId}" name="${fieldName}_id.${objectId}" type="hidden" value="${objectId}">`
|
|
39
|
+
+ `<input name="${fieldName}.${objectId}" ${attrValue}>`
|
|
40
40
|
+ '</li>');
|
|
41
41
|
}
|
|
42
42
|
return label + `<ul data-multiple-contained-auto-width data-fetch="${fetch}" data-type="objects">`
|
|
43
43
|
+ inputs.join('')
|
|
44
44
|
+ '<li>'
|
|
45
|
-
+ `<input name="${fieldName}" placeholder="+">`
|
|
46
45
|
+ `<input id="${fieldId}-id" name="${fieldName}_id" type="hidden">`
|
|
46
|
+
+ `<input name="${fieldName}" placeholder="+">`
|
|
47
47
|
+ '</li>'
|
|
48
48
|
+ '</ul>';
|
|
49
49
|
}
|
package/cjs/store.js
CHANGED
|
@@ -49,7 +49,7 @@ async function storeEdit(value, object, property) {
|
|
|
49
49
|
const inputValue = (textValue === '') ? '' : ` value="${textValue}"`;
|
|
50
50
|
const input = `<input data-fetch="${fetch}" data-type="object" ${name}${inputValue}>`;
|
|
51
51
|
const inputId = `<input id="${fieldId}-id" name="${fieldName}_id" type="hidden" value="${value?.id}">`;
|
|
52
|
-
return label + lfTab +
|
|
52
|
+
return label + lfTab + inputId + input;
|
|
53
53
|
}
|
|
54
54
|
function storeInput(value, object, property, data) {
|
|
55
55
|
const propertyId = property + 'Id';
|
package/esm/collection-type.js
CHANGED
|
@@ -31,15 +31,15 @@ async function collectionEdit(values, object, property) {
|
|
|
31
31
|
const attrValue = `value="${await depends.representativeValueOf(object)}"`;
|
|
32
32
|
const objectId = dataSource().isObjectConnected(object) ? '' + object.id : '';
|
|
33
33
|
inputs.push('<li>'
|
|
34
|
-
+ `<input name="${fieldName}.${objectId}" ${attrValue}>`
|
|
35
34
|
+ `<input id="${fieldId}-id.${objectId}" name="${fieldName}_id.${objectId}" type="hidden" value="${objectId}">`
|
|
35
|
+
+ `<input name="${fieldName}.${objectId}" ${attrValue}>`
|
|
36
36
|
+ '</li>');
|
|
37
37
|
}
|
|
38
38
|
return label + `<ul data-multiple-contained-auto-width data-fetch="${fetch}" data-type="objects">`
|
|
39
39
|
+ inputs.join('')
|
|
40
40
|
+ '<li>'
|
|
41
|
-
+ `<input name="${fieldName}" placeholder="+">`
|
|
42
41
|
+ `<input id="${fieldId}-id" name="${fieldName}_id" type="hidden">`
|
|
42
|
+
+ `<input name="${fieldName}" placeholder="+">`
|
|
43
43
|
+ '</li>'
|
|
44
44
|
+ '</ul>';
|
|
45
45
|
}
|
package/esm/store.js
CHANGED
|
@@ -42,7 +42,7 @@ async function storeEdit(value, object, property) {
|
|
|
42
42
|
const inputValue = (textValue === '') ? '' : ` value="${textValue}"`;
|
|
43
43
|
const input = `<input data-fetch="${fetch}" data-type="object" ${name}${inputValue}>`;
|
|
44
44
|
const inputId = `<input id="${fieldId}-id" name="${fieldName}_id" type="hidden" value="${value?.id}">`;
|
|
45
|
-
return label + lfTab +
|
|
45
|
+
return label + lfTab + inputId + input;
|
|
46
46
|
}
|
|
47
47
|
function storeInput(value, object, property, data) {
|
|
48
48
|
const propertyId = property + 'Id';
|
package/package.json
CHANGED