iptdevs-design-system 3.1.941 → 3.1.943
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/steps/cod-form-step-two/cod-form-step-two.component.mjs +16 -22
- package/esm2020/lib/core/models/terms/terms-rs.model.mjs +1 -1
- package/esm2020/lib/core/services/commercial-service/comercial.service.mjs +11 -1
- package/fesm2015/iptdevs-design-system.mjs +26 -22
- package/fesm2015/iptdevs-design-system.mjs.map +1 -1
- package/fesm2020/iptdevs-design-system.mjs +25 -21
- package/fesm2020/iptdevs-design-system.mjs.map +1 -1
- package/lib/cod/steps/cod-form-step-two/cod-form-step-two.component.d.ts +1 -1
- package/lib/core/models/terms/terms-rs.model.d.ts +180 -0
- package/lib/core/services/commercial-service/comercial.service.d.ts +3 -1
- package/package.json +1 -1
|
@@ -3891,6 +3891,16 @@ class CommercialService extends IPTGeneralService {
|
|
|
3891
3891
|
this.generateRequestParams(params);
|
|
3892
3892
|
return this.http.post(serviceUrl, this.httpOptions);
|
|
3893
3893
|
}
|
|
3894
|
+
extendTimeOfAcceptanceOfTerms(params) {
|
|
3895
|
+
let serviceUrl = this.SERVICE_URL + 'extend/time/of/acceptance/of/terms';
|
|
3896
|
+
this.generateRequestParams(params);
|
|
3897
|
+
return this.http.post(serviceUrl, this.httpOptions);
|
|
3898
|
+
}
|
|
3899
|
+
newTermsAndConditionsAcceptanceToken(params) {
|
|
3900
|
+
let serviceUrl = this.SERVICE_URL + 'new/terms/and/conditions/acceptance/token';
|
|
3901
|
+
this.generateRequestParams(params);
|
|
3902
|
+
return this.http.post(serviceUrl, this.httpOptions);
|
|
3903
|
+
}
|
|
3894
3904
|
}
|
|
3895
3905
|
CommercialService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.0.7", ngImport: i0, type: CommercialService, deps: [{ token: i1$2.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
3896
3906
|
CommercialService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.0.7", ngImport: i0, type: CommercialService, providedIn: 'root' });
|
|
@@ -4898,7 +4908,7 @@ class CodFormStepTwoComponent extends CodFormSteps {
|
|
|
4898
4908
|
state: ['', [Validators.required], []],
|
|
4899
4909
|
city: ['', [Validators.required], []],
|
|
4900
4910
|
student_id_card_type: ['', [Validators.required], []],
|
|
4901
|
-
student_id_card: [{ value: '', disabled: true }, [Validators.required, Validators.minLength(5), Validators.maxLength(20)]],
|
|
4911
|
+
student_id_card: [{ value: '', disabled: true }, [Validators.required, Validators.minLength(5), Validators.maxLength(20), Validators.pattern(/^[a-zA-Z0-9]*$/)]],
|
|
4902
4912
|
student_last_name: ['', [Validators.required, Validators.minLength(5), Validators.maxLength(32)]],
|
|
4903
4913
|
student_name: ['', [Validators.required, Validators.minLength(3), Validators.maxLength(32)]],
|
|
4904
4914
|
student_email: ['', [Validators.required, Validators.email]],
|
|
@@ -5069,35 +5079,29 @@ class CodFormStepTwoComponent extends CodFormSteps {
|
|
|
5069
5079
|
}
|
|
5070
5080
|
}
|
|
5071
5081
|
trackStudentIdCardChanges() {
|
|
5072
|
-
|
|
5073
|
-
|
|
5074
|
-
this.idTypes = (_a = this.parametersAll) === null || _a === void 0 ? void 0 : _a.TypeIdCardByCountryCol;
|
|
5075
|
-
this.codFormStepTwo.controls['student_id_card'].valueChanges.pipe().subscribe(value => {
|
|
5082
|
+
console.log('trackStudentIdCardChanges called'); // Depuración
|
|
5083
|
+
this.codFormStepTwo.controls['student_id_card'].valueChanges.subscribe(value => {
|
|
5076
5084
|
console.log('student_id_card value:', value); // Depuración
|
|
5085
|
+
this.updateIdTypes(value);
|
|
5086
|
+
});
|
|
5087
|
+
}
|
|
5088
|
+
updateIdTypes(value) {
|
|
5089
|
+
var _a;
|
|
5090
|
+
console.log('updateIdTypes called with value:', value); // Depuración
|
|
5091
|
+
if ((_a = this.parametersAll) === null || _a === void 0 ? void 0 : _a.TypeIdCardByCountryCol) {
|
|
5077
5092
|
if (value && /[a-zA-Z]/.test(value)) {
|
|
5078
5093
|
console.log('Contains letters, filtering idTypes'); // Depuración
|
|
5079
|
-
this.
|
|
5094
|
+
this.idTypes = this.parametersAll.TypeIdCardByCountryCol.filter((_, index) => ![0, 1, 2, 7].includes(index));
|
|
5080
5095
|
}
|
|
5081
5096
|
else {
|
|
5082
5097
|
console.log('No letters, restoring idTypes'); // Depuración
|
|
5083
|
-
|
|
5098
|
+
this.idTypes = [...this.parametersAll.TypeIdCardByCountryCol]; // Crear una copia para forzar detección de cambios
|
|
5084
5099
|
}
|
|
5085
5100
|
console.log('Current idTypes:', this.idTypes); // Depuración
|
|
5086
|
-
}
|
|
5087
|
-
|
|
5088
|
-
|
|
5089
|
-
|
|
5090
|
-
// Crear una copia de idTypes para evitar mutar el original directamente
|
|
5091
|
-
let filteredIdTypes = [...this.idTypes];
|
|
5092
|
-
// Ordenar las posiciones de mayor a menor para evitar problemas al eliminar
|
|
5093
|
-
const sortedPositions = positionsToRemove.sort((a, b) => b - a);
|
|
5094
|
-
// Eliminar registros en las posiciones especificadas
|
|
5095
|
-
sortedPositions.forEach(position => {
|
|
5096
|
-
if (position >= 0 && position < filteredIdTypes.length) {
|
|
5097
|
-
filteredIdTypes.splice(position, 1);
|
|
5098
|
-
}
|
|
5099
|
-
});
|
|
5100
|
-
this.idTypes = filteredIdTypes;
|
|
5101
|
+
}
|
|
5102
|
+
else {
|
|
5103
|
+
console.log('TypeIdCardByCountryCol is undefined'); // Depuración
|
|
5104
|
+
this.idTypes = [];
|
|
5101
5105
|
}
|
|
5102
5106
|
}
|
|
5103
5107
|
}
|