@formio/js 5.0.0-bb.dev.3 → 5.0.0-bb.dev.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/dist/formio.embed.js +1 -1
- package/dist/formio.embed.min.js +1 -1
- package/dist/formio.embed.min.js.LICENSE.txt +1 -1
- package/dist/formio.form.js +20 -19
- package/dist/formio.form.min.js +1 -1
- package/dist/formio.form.min.js.LICENSE.txt +1 -1
- package/dist/formio.full.js +20 -19
- package/dist/formio.full.min.js +1 -1
- package/dist/formio.full.min.js.LICENSE.txt +1 -1
- package/dist/formio.js +9 -8
- package/dist/formio.min.js +1 -1
- package/dist/formio.min.js.LICENSE.txt +1 -1
- package/dist/formio.utils.min.js.LICENSE.txt +1 -1
- package/lib/cjs/Form.js +1 -18
- package/lib/cjs/PDFBuilder.d.ts +1 -1
- package/lib/cjs/Webform.d.ts +1 -1
- package/lib/cjs/WebformBuilder.d.ts +4 -4
- package/lib/cjs/Wizard.d.ts +1 -2
- package/lib/cjs/WizardBuilder.d.ts +14 -2
- package/lib/cjs/components/Components.d.ts +6 -6
- package/lib/cjs/components/_classes/component/Component.d.ts +9 -4
- package/lib/cjs/components/_classes/component/Component.form.d.ts +1112 -1
- package/lib/cjs/components/_classes/component/Component.js +10 -4
- package/lib/cjs/components/_classes/component/editForm/Component.edit.validation.js +8 -0
- package/lib/cjs/components/_classes/component/editForm/utils.d.ts +2 -2
- package/lib/cjs/components/_classes/input/Input.d.ts +6 -2
- package/lib/cjs/components/_classes/list/ListComponent.form.d.ts +1112 -1
- package/lib/cjs/components/_classes/nested/NestedComponent.form.d.ts +1112 -1
- package/lib/cjs/components/_classes/nested/NestedComponent.js +2 -2
- package/lib/cjs/components/_classes/nestedarray/NestedArrayComponent.d.ts +1 -1
- package/lib/cjs/components/address/Address.form.d.ts +1112 -1
- package/lib/cjs/components/address/editForm/Address.edit.provider.d.ts +4 -1
- package/lib/cjs/components/button/Button.d.ts +1 -1
- package/lib/cjs/components/button/Button.form.d.ts +1112 -1
- package/lib/cjs/components/checkbox/Checkbox.d.ts +1 -1
- package/lib/cjs/components/checkbox/Checkbox.form.d.ts +1112 -1
- package/lib/cjs/components/columns/Columns.d.ts +2 -0
- package/lib/cjs/components/columns/Columns.form.d.ts +1112 -1
- package/lib/cjs/components/container/Container.form.d.ts +1112 -1
- package/lib/cjs/components/content/Content.form.d.ts +1112 -1
- package/lib/cjs/components/currency/Currency.form.d.ts +1112 -1
- package/lib/cjs/components/datagrid/DataGrid.d.ts +3 -3
- package/lib/cjs/components/datagrid/DataGrid.form.d.ts +1112 -1
- package/lib/cjs/components/datagrid/DataGrid.js +2 -1
- package/lib/cjs/components/datagrid/fixtures/comp-with-allow-calculate-override.js +1 -1
- package/lib/cjs/components/datagrid/fixtures/index.d.ts +2 -1
- package/lib/cjs/components/datagrid/fixtures/index.js +3 -1
- package/lib/cjs/components/datagrid/fixtures/two-comp-with-allow-calculate-override.d.ts +53 -0
- package/lib/cjs/components/datagrid/fixtures/two-comp-with-allow-calculate-override.js +104 -0
- package/lib/cjs/components/datamap/DataMap.d.ts +2 -1
- package/lib/cjs/components/datamap/DataMap.form.d.ts +1112 -1
- package/lib/cjs/components/datetime/DateTime.form.d.ts +1112 -1
- package/lib/cjs/components/day/Day.form.d.ts +1112 -1
- package/lib/cjs/components/editgrid/EditGrid.form.d.ts +1112 -1
- package/lib/cjs/components/editgrid/EditGrid.js +7 -4
- package/lib/cjs/components/editgrid/fixtures/formsWithEditGridAndConditions.d.ts +910 -0
- package/lib/cjs/components/editgrid/fixtures/formsWithEditGridAndConditions.js +923 -0
- package/lib/cjs/components/email/Email.form.d.ts +1112 -1
- package/lib/cjs/components/fieldset/Fieldset.form.d.ts +1112 -1
- package/lib/cjs/components/file/File.d.ts +2 -7
- package/lib/cjs/components/file/File.form.d.ts +1112 -1
- package/lib/cjs/components/file/editForm/File.edit.file.d.ts +4 -1
- package/lib/cjs/components/form/Form.d.ts +1 -1
- package/lib/cjs/components/form/Form.form.d.ts +1112 -1
- package/lib/cjs/components/hidden/Hidden.form.d.ts +1112 -1
- package/lib/cjs/components/html/HTML.d.ts +1 -0
- package/lib/cjs/components/html/HTML.form.d.ts +1112 -1
- package/lib/cjs/components/html/HTML.js +9 -0
- package/lib/cjs/components/number/Number.form.d.ts +1112 -1
- package/lib/cjs/components/panel/Panel.form.d.ts +1112 -1
- package/lib/cjs/components/password/Password.d.ts +2 -0
- package/lib/cjs/components/password/Password.form.d.ts +1112 -1
- package/lib/cjs/components/phonenumber/PhoneNumber.form.d.ts +1112 -1
- package/lib/cjs/components/radio/Radio.d.ts +1 -1
- package/lib/cjs/components/radio/Radio.form.d.ts +1112 -1
- package/lib/cjs/components/recaptcha/ReCaptcha.form.d.ts +1112 -1
- package/lib/cjs/components/recaptcha/ReCaptcha.js +3 -3
- package/lib/cjs/components/select/Select.d.ts +4 -5
- package/lib/cjs/components/select/Select.form.d.ts +1112 -1
- package/lib/cjs/components/selectboxes/SelectBoxes.d.ts +2 -7
- package/lib/cjs/components/selectboxes/SelectBoxes.form.d.ts +1112 -1
- package/lib/cjs/components/signature/Signature.form.d.ts +1112 -1
- package/lib/cjs/components/survey/Survey.d.ts +1 -0
- package/lib/cjs/components/survey/Survey.form.d.ts +1112 -1
- package/lib/cjs/components/table/Table.d.ts +1 -0
- package/lib/cjs/components/table/Table.form.d.ts +1112 -1
- package/lib/cjs/components/tabs/Tabs.form.d.ts +1112 -1
- package/lib/cjs/components/tags/Tags.form.d.ts +1112 -1
- package/lib/cjs/components/textarea/TextArea.d.ts +1 -1
- package/lib/cjs/components/textarea/TextArea.form.d.ts +1112 -1
- package/lib/cjs/components/textarea/editForm/TextArea.edit.display.d.ts +4 -1
- package/lib/cjs/components/textfield/TextField.form.d.ts +1112 -1
- package/lib/cjs/components/time/Time.form.d.ts +1112 -1
- package/lib/cjs/components/url/Url.form.d.ts +1112 -1
- package/lib/cjs/components/well/Well.form.d.ts +1112 -1
- package/lib/cjs/formio.form.d.ts +3 -3
- package/lib/cjs/formio.form.js +59 -46
- package/lib/cjs/providers/address/AddressProvider.d.ts +3 -3
- package/lib/cjs/providers/storage/s3.js +1 -29
- package/lib/cjs/providers/storage/xhr.d.ts +1 -1
- package/lib/cjs/translations/en.d.ts +2 -0
- package/lib/cjs/translations/en.js +2 -0
- package/lib/cjs/utils/builder.d.ts +1 -1
- package/lib/cjs/utils/conditionOperators/ConditionOperator.d.ts +1 -1
- package/lib/cjs/utils/conditionOperators/EndsWith.d.ts +1 -1
- package/lib/cjs/utils/conditionOperators/GreaterThan.d.ts +1 -1
- package/lib/cjs/utils/conditionOperators/GreaterThanOrEqual.d.ts +1 -1
- package/lib/cjs/utils/conditionOperators/Includes.d.ts +1 -1
- package/lib/cjs/utils/conditionOperators/LessThan.d.ts +1 -1
- package/lib/cjs/utils/conditionOperators/LessThanOrEqual.d.ts +1 -1
- package/lib/cjs/utils/conditionOperators/StartsWith.d.ts +1 -1
- package/lib/cjs/utils/conditionOperators/index.d.ts +2 -2
- package/lib/cjs/utils/utils.d.ts +4 -3
- package/lib/cjs/validator/Validator.d.ts +8 -3
- package/lib/cjs/validator/Validator.js +1 -1
- package/lib/mjs/Form.js +1 -18
- package/lib/mjs/PDFBuilder.d.ts +1 -1
- package/lib/mjs/Webform.d.ts +1 -1
- package/lib/mjs/WebformBuilder.d.ts +4 -4
- package/lib/mjs/Wizard.d.ts +1 -2
- package/lib/mjs/WizardBuilder.d.ts +14 -2
- package/lib/mjs/components/Components.d.ts +6 -6
- package/lib/mjs/components/_classes/component/Component.d.ts +9 -4
- package/lib/mjs/components/_classes/component/Component.form.d.ts +1112 -1
- package/lib/mjs/components/_classes/component/Component.js +10 -4
- package/lib/mjs/components/_classes/component/editForm/Component.edit.validation.js +8 -0
- package/lib/mjs/components/_classes/component/editForm/utils.d.ts +2 -2
- package/lib/mjs/components/_classes/input/Input.d.ts +6 -2
- package/lib/mjs/components/_classes/list/ListComponent.form.d.ts +1112 -1
- package/lib/mjs/components/_classes/nested/NestedComponent.form.d.ts +1112 -1
- package/lib/mjs/components/_classes/nested/NestedComponent.js +2 -2
- package/lib/mjs/components/_classes/nestedarray/NestedArrayComponent.d.ts +1 -1
- package/lib/mjs/components/address/Address.form.d.ts +1112 -1
- package/lib/mjs/components/address/editForm/Address.edit.provider.d.ts +4 -1
- package/lib/mjs/components/button/Button.d.ts +1 -1
- package/lib/mjs/components/button/Button.form.d.ts +1112 -1
- package/lib/mjs/components/checkbox/Checkbox.d.ts +1 -1
- package/lib/mjs/components/checkbox/Checkbox.form.d.ts +1112 -1
- package/lib/mjs/components/columns/Columns.d.ts +2 -0
- package/lib/mjs/components/columns/Columns.form.d.ts +1112 -1
- package/lib/mjs/components/container/Container.form.d.ts +1112 -1
- package/lib/mjs/components/content/Content.form.d.ts +1112 -1
- package/lib/mjs/components/currency/Currency.form.d.ts +1112 -1
- package/lib/mjs/components/datagrid/DataGrid.d.ts +3 -3
- package/lib/mjs/components/datagrid/DataGrid.form.d.ts +1112 -1
- package/lib/mjs/components/datagrid/DataGrid.js +2 -1
- package/lib/mjs/components/datagrid/fixtures/comp-with-allow-calculate-override.js +1 -1
- package/lib/mjs/components/datagrid/fixtures/index.d.ts +2 -1
- package/lib/mjs/components/datagrid/fixtures/index.js +2 -1
- package/lib/mjs/components/datagrid/fixtures/two-comp-with-allow-calculate-override.d.ts +53 -0
- package/lib/mjs/components/datagrid/fixtures/two-comp-with-allow-calculate-override.js +102 -0
- package/lib/mjs/components/datamap/DataMap.d.ts +2 -1
- package/lib/mjs/components/datamap/DataMap.form.d.ts +1112 -1
- package/lib/mjs/components/datetime/DateTime.form.d.ts +1112 -1
- package/lib/mjs/components/day/Day.form.d.ts +1112 -1
- package/lib/mjs/components/editgrid/EditGrid.form.d.ts +1112 -1
- package/lib/mjs/components/editgrid/EditGrid.js +7 -4
- package/lib/mjs/components/editgrid/fixtures/formsWithEditGridAndConditions.d.ts +910 -0
- package/lib/mjs/components/editgrid/fixtures/formsWithEditGridAndConditions.js +921 -0
- package/lib/mjs/components/email/Email.form.d.ts +1112 -1
- package/lib/mjs/components/fieldset/Fieldset.form.d.ts +1112 -1
- package/lib/mjs/components/file/File.d.ts +2 -7
- package/lib/mjs/components/file/File.form.d.ts +1112 -1
- package/lib/mjs/components/file/editForm/File.edit.file.d.ts +4 -1
- package/lib/mjs/components/form/Form.d.ts +1 -1
- package/lib/mjs/components/form/Form.form.d.ts +1112 -1
- package/lib/mjs/components/hidden/Hidden.form.d.ts +1112 -1
- package/lib/mjs/components/html/HTML.d.ts +1 -0
- package/lib/mjs/components/html/HTML.form.d.ts +1112 -1
- package/lib/mjs/components/html/HTML.js +8 -0
- package/lib/mjs/components/number/Number.form.d.ts +1112 -1
- package/lib/mjs/components/panel/Panel.form.d.ts +1112 -1
- package/lib/mjs/components/password/Password.d.ts +2 -0
- package/lib/mjs/components/password/Password.form.d.ts +1112 -1
- package/lib/mjs/components/phonenumber/PhoneNumber.form.d.ts +1112 -1
- package/lib/mjs/components/radio/Radio.d.ts +1 -1
- package/lib/mjs/components/radio/Radio.form.d.ts +1112 -1
- package/lib/mjs/components/recaptcha/ReCaptcha.form.d.ts +1112 -1
- package/lib/mjs/components/recaptcha/ReCaptcha.js +3 -3
- package/lib/mjs/components/select/Select.d.ts +4 -5
- package/lib/mjs/components/select/Select.form.d.ts +1112 -1
- package/lib/mjs/components/selectboxes/SelectBoxes.d.ts +2 -7
- package/lib/mjs/components/selectboxes/SelectBoxes.form.d.ts +1112 -1
- package/lib/mjs/components/signature/Signature.form.d.ts +1112 -1
- package/lib/mjs/components/survey/Survey.d.ts +1 -0
- package/lib/mjs/components/survey/Survey.form.d.ts +1112 -1
- package/lib/mjs/components/table/Table.d.ts +1 -0
- package/lib/mjs/components/table/Table.form.d.ts +1112 -1
- package/lib/mjs/components/tabs/Tabs.form.d.ts +1112 -1
- package/lib/mjs/components/tags/Tags.form.d.ts +1112 -1
- package/lib/mjs/components/textarea/TextArea.d.ts +1 -1
- package/lib/mjs/components/textarea/TextArea.form.d.ts +1112 -1
- package/lib/mjs/components/textarea/editForm/TextArea.edit.display.d.ts +4 -1
- package/lib/mjs/components/textfield/TextField.form.d.ts +1112 -1
- package/lib/mjs/components/time/Time.form.d.ts +1112 -1
- package/lib/mjs/components/url/Url.form.d.ts +1112 -1
- package/lib/mjs/components/well/Well.form.d.ts +1112 -1
- package/lib/mjs/formio.form.d.ts +3 -3
- package/lib/mjs/formio.form.js +58 -44
- package/lib/mjs/providers/address/AddressProvider.d.ts +3 -3
- package/lib/mjs/providers/storage/s3.js +1 -6
- package/lib/mjs/providers/storage/xhr.d.ts +1 -1
- package/lib/mjs/translations/en.d.ts +2 -0
- package/lib/mjs/translations/en.js +2 -0
- package/lib/mjs/utils/builder.d.ts +1 -1
- package/lib/mjs/utils/conditionOperators/ConditionOperator.d.ts +1 -1
- package/lib/mjs/utils/conditionOperators/EndsWith.d.ts +1 -1
- package/lib/mjs/utils/conditionOperators/GreaterThan.d.ts +1 -1
- package/lib/mjs/utils/conditionOperators/GreaterThanOrEqual.d.ts +1 -1
- package/lib/mjs/utils/conditionOperators/Includes.d.ts +1 -1
- package/lib/mjs/utils/conditionOperators/LessThan.d.ts +1 -1
- package/lib/mjs/utils/conditionOperators/LessThanOrEqual.d.ts +1 -1
- package/lib/mjs/utils/conditionOperators/StartsWith.d.ts +1 -1
- package/lib/mjs/utils/conditionOperators/index.d.ts +2 -2
- package/lib/mjs/utils/utils.d.ts +4 -3
- package/lib/mjs/validator/Validator.d.ts +8 -3
- package/lib/mjs/validator/Validator.js +1 -1
- package/package.json +1 -1
|
@@ -587,7 +587,8 @@ class DataGridComponent extends NestedArrayComponent_1.default {
|
|
|
587
587
|
const isSettingSubmission = flags.fromSubmission && !lodash_1.default.isEqual(value, this.emptyValue);
|
|
588
588
|
const changed = this.hasChanged(value, this.dataValue);
|
|
589
589
|
this.dataValue = value;
|
|
590
|
-
if (this.initRows || isSettingSubmission
|
|
590
|
+
if (this.initRows || isSettingSubmission ||
|
|
591
|
+
(Array.isArray(this.dataValue) && this.dataValue.length !== this.rows.length)) {
|
|
591
592
|
if (!this.createRows() && changed) {
|
|
592
593
|
this.redraw();
|
|
593
594
|
}
|
|
@@ -42,7 +42,7 @@ exports.default = {
|
|
|
42
42
|
lastName: ''
|
|
43
43
|
}
|
|
44
44
|
],
|
|
45
|
-
calculateValue: "var temp =
|
|
45
|
+
calculateValue: "var temp = instance.defaultValue;\n if(data.select === 'a')\n {\n temp = [{'firstName': 'A f 1','lastName': 'A l 1'}];\n } else if(data.select === 'b') { \n temp = [{'firstName': 'B f 1','lastName': 'B l 1'} \n ,{'firstName': 'B f 2','lastName': 'B l 2'}];\n } else if(data.select === 'c') { \n temp = [{'firstName': 'C f 1','lastName': 'C l 1'}];\n }\n value = temp;",
|
|
46
46
|
allowCalculateOverride: true,
|
|
47
47
|
key: 'dataGrid',
|
|
48
48
|
type: 'datagrid',
|
|
@@ -13,4 +13,5 @@ import withLogic from './comp-with-logic';
|
|
|
13
13
|
import withRowGroupsAndDefValue from './comp-row-groups-with-def-value';
|
|
14
14
|
import modalWithRequiredFields from './comp-modal-with-required-fields';
|
|
15
15
|
import withAllowCalculateOverride from './comp-with-allow-calculate-override';
|
|
16
|
-
|
|
16
|
+
import twoWithAllowCalculatedOverride from './two-comp-with-allow-calculate-override';
|
|
17
|
+
export { comp1, comp2, comp3, comp4, comp5, comp6, comp7, comp8, withCollapsibleRowGroups, withConditionalFieldsAndValidations, withDefValue, withLogic, withRowGroupsAndDefValue, modalWithRequiredFields, withAllowCalculateOverride, twoWithAllowCalculatedOverride };
|
|
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.withAllowCalculateOverride = exports.modalWithRequiredFields = exports.withRowGroupsAndDefValue = exports.withLogic = exports.withDefValue = exports.withConditionalFieldsAndValidations = exports.withCollapsibleRowGroups = exports.comp8 = exports.comp7 = exports.comp6 = exports.comp5 = exports.comp4 = exports.comp3 = exports.comp2 = exports.comp1 = void 0;
|
|
6
|
+
exports.twoWithAllowCalculatedOverride = exports.withAllowCalculateOverride = exports.modalWithRequiredFields = exports.withRowGroupsAndDefValue = exports.withLogic = exports.withDefValue = exports.withConditionalFieldsAndValidations = exports.withCollapsibleRowGroups = exports.comp8 = exports.comp7 = exports.comp6 = exports.comp5 = exports.comp4 = exports.comp3 = exports.comp2 = exports.comp1 = void 0;
|
|
7
7
|
const comp1_1 = __importDefault(require("./comp1"));
|
|
8
8
|
exports.comp1 = comp1_1.default;
|
|
9
9
|
const comp2_1 = __importDefault(require("./comp2"));
|
|
@@ -34,3 +34,5 @@ const comp_with_collapsible_groups_1 = __importDefault(require("./comp-with-coll
|
|
|
34
34
|
exports.withCollapsibleRowGroups = comp_with_collapsible_groups_1.default;
|
|
35
35
|
const comp_with_allow_calculate_override_1 = __importDefault(require("./comp-with-allow-calculate-override"));
|
|
36
36
|
exports.withAllowCalculateOverride = comp_with_allow_calculate_override_1.default;
|
|
37
|
+
const two_comp_with_allow_calculate_override_1 = __importDefault(require("./two-comp-with-allow-calculate-override"));
|
|
38
|
+
exports.twoWithAllowCalculatedOverride = two_comp_with_allow_calculate_override_1.default;
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
declare namespace _default {
|
|
2
|
+
const type: string;
|
|
3
|
+
const display: string;
|
|
4
|
+
const components: ({
|
|
5
|
+
label: string;
|
|
6
|
+
widget: string;
|
|
7
|
+
tableView: boolean;
|
|
8
|
+
data: {
|
|
9
|
+
values: {
|
|
10
|
+
label: string;
|
|
11
|
+
value: string;
|
|
12
|
+
}[];
|
|
13
|
+
};
|
|
14
|
+
key: string;
|
|
15
|
+
type: string;
|
|
16
|
+
input: boolean;
|
|
17
|
+
reorder?: undefined;
|
|
18
|
+
addAnotherPosition?: undefined;
|
|
19
|
+
layoutFixed?: undefined;
|
|
20
|
+
enableRowGroups?: undefined;
|
|
21
|
+
initEmpty?: undefined;
|
|
22
|
+
defaultValue?: undefined;
|
|
23
|
+
allowCalculateOverride?: undefined;
|
|
24
|
+
components?: undefined;
|
|
25
|
+
} | {
|
|
26
|
+
label: string;
|
|
27
|
+
reorder: boolean;
|
|
28
|
+
addAnotherPosition: string;
|
|
29
|
+
layoutFixed: boolean;
|
|
30
|
+
enableRowGroups: boolean;
|
|
31
|
+
initEmpty: boolean;
|
|
32
|
+
tableView: boolean;
|
|
33
|
+
defaultValue: {
|
|
34
|
+
firstName: string;
|
|
35
|
+
lastName: string;
|
|
36
|
+
}[];
|
|
37
|
+
calculateValue: string;
|
|
38
|
+
allowCalculateOverride: boolean;
|
|
39
|
+
key: string;
|
|
40
|
+
type: string;
|
|
41
|
+
input: boolean;
|
|
42
|
+
components: {
|
|
43
|
+
label: string;
|
|
44
|
+
tableView: boolean;
|
|
45
|
+
key: string;
|
|
46
|
+
type: string;
|
|
47
|
+
input: boolean;
|
|
48
|
+
}[];
|
|
49
|
+
widget?: undefined;
|
|
50
|
+
data?: undefined;
|
|
51
|
+
})[];
|
|
52
|
+
}
|
|
53
|
+
export default _default;
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.default = {
|
|
4
|
+
type: 'form',
|
|
5
|
+
display: 'form',
|
|
6
|
+
components: [
|
|
7
|
+
{
|
|
8
|
+
label: 'Select',
|
|
9
|
+
widget: 'choicesjs',
|
|
10
|
+
tableView: true,
|
|
11
|
+
data: {
|
|
12
|
+
values: [
|
|
13
|
+
{
|
|
14
|
+
label: 'a',
|
|
15
|
+
value: 'a'
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
label: 'b',
|
|
19
|
+
value: 'b'
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
label: 'c',
|
|
23
|
+
value: 'c'
|
|
24
|
+
}
|
|
25
|
+
]
|
|
26
|
+
},
|
|
27
|
+
key: 'select',
|
|
28
|
+
type: 'select',
|
|
29
|
+
input: true
|
|
30
|
+
},
|
|
31
|
+
{
|
|
32
|
+
label: 'Data Grid',
|
|
33
|
+
reorder: false,
|
|
34
|
+
addAnotherPosition: 'bottom',
|
|
35
|
+
layoutFixed: false,
|
|
36
|
+
enableRowGroups: false,
|
|
37
|
+
initEmpty: false,
|
|
38
|
+
tableView: false,
|
|
39
|
+
defaultValue: [
|
|
40
|
+
{
|
|
41
|
+
firstName: '',
|
|
42
|
+
lastName: ''
|
|
43
|
+
}
|
|
44
|
+
],
|
|
45
|
+
calculateValue: "var temp = instance.defaultValue;\n if(data.select === 'a')\n {\n temp = [{'firstName': 'A f 1','lastName': 'A l 1'}];\n } else if(data.select === 'b') { \n temp = [{'firstName': 'B f 1','lastName': 'B l 1'} \n ,{'firstName': 'B f 2','lastName': 'B l 2'}];\n } else if(data.select === 'c') { \n temp = [{'firstName': 'C f 1','lastName': 'C l 1'}];\n }\n value = temp;",
|
|
46
|
+
allowCalculateOverride: true,
|
|
47
|
+
key: 'dataGrid',
|
|
48
|
+
type: 'datagrid',
|
|
49
|
+
input: true,
|
|
50
|
+
components: [
|
|
51
|
+
{
|
|
52
|
+
label: 'First Name',
|
|
53
|
+
tableView: true,
|
|
54
|
+
key: 'firstName',
|
|
55
|
+
type: 'textfield',
|
|
56
|
+
input: true
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
label: 'Last Name',
|
|
60
|
+
tableView: true,
|
|
61
|
+
key: 'lastName',
|
|
62
|
+
type: 'textfield',
|
|
63
|
+
input: true
|
|
64
|
+
}
|
|
65
|
+
]
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
label: 'Data Grid 2',
|
|
69
|
+
reorder: false,
|
|
70
|
+
addAnotherPosition: 'bottom',
|
|
71
|
+
layoutFixed: false,
|
|
72
|
+
enableRowGroups: false,
|
|
73
|
+
initEmpty: false,
|
|
74
|
+
tableView: false,
|
|
75
|
+
defaultValue: [
|
|
76
|
+
{
|
|
77
|
+
firstName: '',
|
|
78
|
+
lastName: ''
|
|
79
|
+
}
|
|
80
|
+
],
|
|
81
|
+
calculateValue: "var temp = instance.defaultValue;\n if(data.select === 'a')\n {\n temp = [{'firstName': 'A f 1','lastName': 'A l 1'}];\n } else if(data.select === 'b') { \n temp = [{'firstName': 'B f 1','lastName': 'B l 1'} \n ,{'firstName': 'B f 2','lastName': 'B l 2'}];\n } else if(data.select === 'c') { \n temp = [{'firstName': 'C f 1','lastName': 'C l 1'}];\n }\n value = temp;",
|
|
82
|
+
allowCalculateOverride: true,
|
|
83
|
+
key: 'dataGrid2',
|
|
84
|
+
type: 'datagrid',
|
|
85
|
+
input: true,
|
|
86
|
+
components: [
|
|
87
|
+
{
|
|
88
|
+
label: 'First Name',
|
|
89
|
+
tableView: true,
|
|
90
|
+
key: 'firstName',
|
|
91
|
+
type: 'textfield',
|
|
92
|
+
input: true
|
|
93
|
+
},
|
|
94
|
+
{
|
|
95
|
+
label: 'Last Name',
|
|
96
|
+
tableView: true,
|
|
97
|
+
key: 'lastName',
|
|
98
|
+
type: 'textfield',
|
|
99
|
+
input: true
|
|
100
|
+
}
|
|
101
|
+
]
|
|
102
|
+
}
|
|
103
|
+
]
|
|
104
|
+
};
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
export default class DataMapComponent extends DataGridComponent {
|
|
2
2
|
static savedValueTypes(schema: any): string[];
|
|
3
3
|
constructor(component: any, options: any, data: any);
|
|
4
|
+
get schema(): Pick<any, string | number | symbol>;
|
|
4
5
|
get emptyValue(): {};
|
|
5
6
|
set dataValue(arg: any);
|
|
6
7
|
get dataValue(): any;
|
|
7
|
-
get defaultValue():
|
|
8
|
+
get defaultValue(): {};
|
|
8
9
|
get keySchema(): {
|
|
9
10
|
type: string;
|
|
10
11
|
input: boolean;
|