iptdevs-design-system 3.1.237 → 3.1.238
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/esm2020/lib/cod/cod-form/cod-form.component.mjs +29 -33
- package/esm2020/lib/cod/logic/cod-form-controls.mjs +2 -1
- package/fesm2015/iptdevs-design-system.mjs +29 -32
- package/fesm2015/iptdevs-design-system.mjs.map +1 -1
- package/fesm2020/iptdevs-design-system.mjs +29 -32
- package/fesm2020/iptdevs-design-system.mjs.map +1 -1
- package/package.json +1 -1
|
@@ -2553,6 +2553,7 @@ class CodFormControls {
|
|
|
2553
2553
|
],
|
|
2554
2554
|
];
|
|
2555
2555
|
this.$controls = new BehaviorSubject([]);
|
|
2556
|
+
this.$controls.next(this.controls);
|
|
2556
2557
|
}
|
|
2557
2558
|
getControlValues() {
|
|
2558
2559
|
return this.$controls.asObservable();
|
|
@@ -4676,40 +4677,36 @@ class CodFormComponent {
|
|
|
4676
4677
|
const totalData = [];
|
|
4677
4678
|
this.subscription = this.codFormControls.getControlValues().subscribe((controls) => {
|
|
4678
4679
|
console.log(controls);
|
|
4679
|
-
|
|
4680
|
-
|
|
4681
|
-
|
|
4682
|
-
|
|
4683
|
-
|
|
4684
|
-
|
|
4685
|
-
|
|
4686
|
-
|
|
4687
|
-
|
|
4688
|
-
|
|
4689
|
-
|
|
4690
|
-
value: '0',
|
|
4691
|
-
description: control.description
|
|
4692
|
-
});
|
|
4693
|
-
}
|
|
4694
|
-
else if (value === 'true' && control.description === 'Multiculturalismo') {
|
|
4695
|
-
totalData.push({
|
|
4696
|
-
control: control.name,
|
|
4697
|
-
isRequired: control.required,
|
|
4698
|
-
value: '1',
|
|
4699
|
-
description: control.description
|
|
4700
|
-
});
|
|
4701
|
-
}
|
|
4702
|
-
else {
|
|
4703
|
-
totalData.push({
|
|
4704
|
-
control: control.name,
|
|
4705
|
-
isRequired: control.required,
|
|
4706
|
-
value,
|
|
4707
|
-
description: control.description
|
|
4708
|
-
});
|
|
4709
|
-
}
|
|
4680
|
+
for (let i = 1; i <= this.formSteps; i++) {
|
|
4681
|
+
let controlsByStep = controls[i - 1];
|
|
4682
|
+
controlsByStep.forEach(control => {
|
|
4683
|
+
let value = this.localStorageCOD.getCodFormData(i, control.name);
|
|
4684
|
+
// Cambiar True/False del multiculturalismo 1/0
|
|
4685
|
+
if (value === 'false' && control.description === 'Multiculturalismo') {
|
|
4686
|
+
totalData.push({
|
|
4687
|
+
control: control.name,
|
|
4688
|
+
isRequired: control.required,
|
|
4689
|
+
value: '0',
|
|
4690
|
+
description: control.description
|
|
4710
4691
|
});
|
|
4711
4692
|
}
|
|
4712
|
-
|
|
4693
|
+
else if (value === 'true' && control.description === 'Multiculturalismo') {
|
|
4694
|
+
totalData.push({
|
|
4695
|
+
control: control.name,
|
|
4696
|
+
isRequired: control.required,
|
|
4697
|
+
value: '1',
|
|
4698
|
+
description: control.description
|
|
4699
|
+
});
|
|
4700
|
+
}
|
|
4701
|
+
else {
|
|
4702
|
+
totalData.push({
|
|
4703
|
+
control: control.name,
|
|
4704
|
+
isRequired: control.required,
|
|
4705
|
+
value,
|
|
4706
|
+
description: control.description
|
|
4707
|
+
});
|
|
4708
|
+
}
|
|
4709
|
+
});
|
|
4713
4710
|
}
|
|
4714
4711
|
// Validar errores
|
|
4715
4712
|
for (let i = 0; i < totalData.length; i++) {
|