iptdevs-design-system 3.1.937 → 3.1.939
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 +15 -7
- package/esm2020/lib/core/models/terms/terms-rs.model.mjs +2 -0
- package/esm2020/lib/core/services/commercial-service/comercial.service.mjs +6 -1
- package/fesm2015/iptdevs-design-system.mjs +26 -14
- package/fesm2015/iptdevs-design-system.mjs.map +1 -1
- package/fesm2020/iptdevs-design-system.mjs +19 -7
- package/fesm2020/iptdevs-design-system.mjs.map +1 -1
- package/lib/cod/steps/cod-form-step-two/cod-form-step-two.component.d.ts +4 -2
- package/lib/core/models/terms/terms-rs.model.d.ts +196 -0
- package/lib/core/services/commercial-service/comercial.service.d.ts +2 -0
- package/package.json +1 -1
|
@@ -28,7 +28,8 @@ import * as i4 from 'primeng/skeleton';
|
|
|
28
28
|
import { SkeletonModule } from 'primeng/skeleton';
|
|
29
29
|
import * as i6$1 from 'primeng/button';
|
|
30
30
|
import { ButtonModule } from 'primeng/button';
|
|
31
|
-
import { BehaviorSubject, finalize, map } from 'rxjs';
|
|
31
|
+
import { BehaviorSubject, finalize, Subject, map } from 'rxjs';
|
|
32
|
+
import { takeUntil } from 'rxjs/operators';
|
|
32
33
|
import * as i11 from 'primeng/table';
|
|
33
34
|
import { TableModule } from 'primeng/table';
|
|
34
35
|
import * as i5$1 from '@angular/material/checkbox';
|
|
@@ -3886,6 +3887,11 @@ class CommercialService extends IPTGeneralService {
|
|
|
3886
3887
|
this.generateRequestParams(params);
|
|
3887
3888
|
return this.http.post(serviceUrl, this.httpOptions);
|
|
3888
3889
|
}
|
|
3890
|
+
obtainCodByAdvisorWithTheirStates(params) {
|
|
3891
|
+
let serviceUrl = this.SERVICE_URL + 'obtain/cod/by/advisor/with/their/states';
|
|
3892
|
+
this.generateRequestParams(params);
|
|
3893
|
+
return this.http.post(serviceUrl, this.httpOptions);
|
|
3894
|
+
}
|
|
3889
3895
|
}
|
|
3890
3896
|
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 });
|
|
3891
3897
|
CommercialService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.0.7", ngImport: i0, type: CommercialService, providedIn: 'root' });
|
|
@@ -4778,6 +4784,7 @@ class CodFormStepTwoComponent extends CodFormSteps {
|
|
|
4778
4784
|
super();
|
|
4779
4785
|
this.fb = fb;
|
|
4780
4786
|
this.changeStepEvent = new EventEmitter();
|
|
4787
|
+
this.destroy$ = new Subject();
|
|
4781
4788
|
this.errorMessage = 'Faltan campos por llenar.';
|
|
4782
4789
|
this.hasErrors = false;
|
|
4783
4790
|
this.genders = [];
|
|
@@ -4801,6 +4808,10 @@ class CodFormStepTwoComponent extends CodFormSteps {
|
|
|
4801
4808
|
}
|
|
4802
4809
|
}
|
|
4803
4810
|
}
|
|
4811
|
+
ngOnDestroy() {
|
|
4812
|
+
this.destroy$.next();
|
|
4813
|
+
this.destroy$.complete();
|
|
4814
|
+
}
|
|
4804
4815
|
setDataFromUserHistory() {
|
|
4805
4816
|
this.codFormStepTwo.controls['student_name'].setValue(this.initialData.name);
|
|
4806
4817
|
this.codFormStepTwo.controls['student_last_name'].setValue(this.initialData.last_name);
|
|
@@ -4925,7 +4936,7 @@ class CodFormStepTwoComponent extends CodFormSteps {
|
|
|
4925
4936
|
});
|
|
4926
4937
|
}
|
|
4927
4938
|
getParameters() {
|
|
4928
|
-
this.idTypes =
|
|
4939
|
+
// this.idTypes =this.parametersAll?.TypeIdCardByCountryCol;
|
|
4929
4940
|
this.indicatives = this.parametersAll?.indicatives;
|
|
4930
4941
|
this.countries = this.parametersAll?.country;
|
|
4931
4942
|
this.stratums = this.parametersAll?.stratum;
|
|
@@ -5050,18 +5061,19 @@ class CodFormStepTwoComponent extends CodFormSteps {
|
|
|
5050
5061
|
}
|
|
5051
5062
|
}
|
|
5052
5063
|
trackStudentIdCardChanges() {
|
|
5053
|
-
this.codFormStepTwo.controls['student_id_card'].valueChanges.subscribe(value => {
|
|
5064
|
+
this.codFormStepTwo.controls['student_id_card'].valueChanges.pipe(takeUntil(this.destroy$)).subscribe(value => {
|
|
5065
|
+
console.log('student_id_card value:', value); // Depuración
|
|
5054
5066
|
if (value && /[a-zA-Z]/.test(value)) {
|
|
5055
|
-
|
|
5056
|
-
this.filterIdTypes([0, 1, 2, 7]);
|
|
5067
|
+
console.log('Contains letters, filtering idTypes'); // Depuración
|
|
5068
|
+
this.filterIdTypes([0, 1, 2, 7]);
|
|
5057
5069
|
}
|
|
5058
5070
|
else {
|
|
5059
|
-
|
|
5071
|
+
console.log('No letters, restoring idTypes'); // Depuración
|
|
5060
5072
|
this.idTypes = this.parametersAll?.TypeIdCardByCountryCol || [];
|
|
5061
5073
|
}
|
|
5074
|
+
console.log('Current idTypes:', this.idTypes); // Depuración
|
|
5062
5075
|
});
|
|
5063
5076
|
}
|
|
5064
|
-
// Método para filtrar idTypes eliminando registros en las posiciones especificadas
|
|
5065
5077
|
filterIdTypes(positionsToRemove) {
|
|
5066
5078
|
if (this.idTypes && Array.isArray(this.idTypes)) {
|
|
5067
5079
|
// Crear una copia de idTypes para evitar mutar el original directamente
|