iptdevs-design-system 3.2.9 → 3.2.10

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.
@@ -1955,7 +1955,6 @@ class updateUserFormComponent {
1955
1955
  (_b = this.updateUserForm.get('status')) === null || _b === void 0 ? void 0 : _b.disable({ emitEvent: false });
1956
1956
  }
1957
1957
  else {
1958
- // Lista reducida para otros roles
1959
1958
  this.justifyOptions = [
1960
1959
  { name: 'Activo', code: 1 },
1961
1960
  { name: 'Removido', code: 4 }
@@ -2061,7 +2060,6 @@ class updateUserFormComponent {
2061
2060
  initializeForm() {
2062
2061
  var _a, _b, _c;
2063
2062
  this.showParentSection = !!((_c = (_b = (_a = this.DataStudent) === null || _a === void 0 ? void 0 : _a.cods) === null || _b === void 0 ? void 0 : _b.parent) === null || _c === void 0 ? void 0 : _c.code);
2064
- // this.showEmailIpt = !!this.DataStudent?.email_ipt && this.DataStudent.email_ipt !== false;
2065
2063
  this.checkRoleForAdditionalFields(this.DataStudent.role);
2066
2064
  this.initForm();
2067
2065
  this.populateForm();
@@ -2190,9 +2188,7 @@ class updateUserFormComponent {
2190
2188
  country: (_a = this.DataStudent.city) === null || _a === void 0 ? void 0 : _a.country,
2191
2189
  state: (_b = this.DataStudent.city) === null || _b === void 0 ? void 0 : _b.state,
2192
2190
  city: (_c = this.DataStudent.city) === null || _c === void 0 ? void 0 : _c.code,
2193
- // role: this.transformRole(this.DataStudent.role) || '',
2194
2191
  role: this.canEditRole ? this.DataStudent.role : this.transformRole(this.DataStudent.role) || '',
2195
- // service_hour: this.DataStudent.service_hour || 0,
2196
2192
  changePassword: false,
2197
2193
  password: '',
2198
2194
  re_password: '',
@@ -2206,9 +2202,6 @@ class updateUserFormComponent {
2206
2202
  else {
2207
2203
  formValue.service_hour = this.DataStudent.service_hour || 0;
2208
2204
  }
2209
- // if (this.showEmailIpt) {
2210
- // formValue.email_ipt = this.DataStudent.email_ipt || '';
2211
- // }
2212
2205
  if (this.showParentSection) {
2213
2206
  Object.assign(formValue, {
2214
2207
  parent_name: ((_e = (_d = this.DataStudent.cods) === null || _d === void 0 ? void 0 : _d.parent) === null || _e === void 0 ? void 0 : _e.name) || '',
@@ -2416,7 +2409,6 @@ class updateUserFormComponent {
2416
2409
  var _a, _b;
2417
2410
  if (role !== null) {
2418
2411
  (_a = this.updateUserForm.get('role')) === null || _a === void 0 ? void 0 : _a.setValue(role);
2419
- // Verificar si se deben mostrar los campos adicionales
2420
2412
  const previousShowEmailIptAndServiceHour = this.showEmailIptAndServiceHour;
2421
2413
  this.checkRoleForAdditionalFields(role);
2422
2414
  // Si showEmailIptAndServiceHour cambió, actualizar los validadores
@@ -2443,7 +2435,6 @@ class updateUserFormComponent {
2443
2435
  }
2444
2436
  }
2445
2437
  else {
2446
- // Remover validadores si los campos no son necesarios
2447
2438
  if (emailIptControl) {
2448
2439
  emailIptControl.clearValidators();
2449
2440
  emailIptControl.setValue('');
@@ -2453,7 +2444,6 @@ class updateUserFormComponent {
2453
2444
  serviceHourControl.setValue(0);
2454
2445
  }
2455
2446
  }
2456
- // Actualizar la validez de los controles
2457
2447
  emailIptControl === null || emailIptControl === void 0 ? void 0 : emailIptControl.updateValueAndValidity();
2458
2448
  serviceHourControl === null || serviceHourControl === void 0 ? void 0 : serviceHourControl.updateValueAndValidity();
2459
2449
  }
@@ -2529,7 +2519,6 @@ class updateUserFormComponent {
2529
2519
  originalValue = this.DataStudent.email || '';
2530
2520
  break;
2531
2521
  case 'email_ipt':
2532
- // originalValue = this.DataStudent.email_ipt || '';
2533
2522
  originalValue = this.showEmailIptAndServiceHour ? (this.DataStudent.email_ipt || '') : '';
2534
2523
  break;
2535
2524
  case 'gender':
@@ -2557,11 +2546,9 @@ class updateUserFormComponent {
2557
2546
  originalValue = ((_c = this.DataStudent.city) === null || _c === void 0 ? void 0 : _c.code) || '';
2558
2547
  break;
2559
2548
  case 'role':
2560
- // originalValue = this.transformRole(this.DataStudent.role) || '';
2561
2549
  originalValue = this.canEditRole ? this.DataStudent.role : this.transformRole(this.DataStudent.role) || '';
2562
2550
  break;
2563
2551
  case 'service_hour':
2564
- // originalValue = this.DataStudent.service_hour || '' ;
2565
2552
  originalValue = this.showEmailIptAndServiceHour ? (this.DataStudent.service_hour || 0) : 0;
2566
2553
  break;
2567
2554
  case 'status':
@@ -2610,11 +2597,6 @@ class updateUserFormComponent {
2610
2597
  this.updateUserForm.hasError('mismatch') ||
2611
2598
  !this.hasFormChanged()) {
2612
2599
  this.updateUserForm.markAllAsTouched();
2613
- console.log('Validation failed:', {
2614
- invalid: this.updateUserForm.invalid,
2615
- mismatch: this.updateUserForm.hasError('mismatch'),
2616
- hasChanges: this.hasFormChanged()
2617
- });
2618
2600
  return;
2619
2601
  }
2620
2602
  this.showConfirmSection = true;
@@ -2691,11 +2673,6 @@ class updateUserFormComponent {
2691
2673
  this.updateUserForm.hasError('mismatch') ||
2692
2674
  !this.hasFormChanged()) {
2693
2675
  this.updateUserForm.markAllAsTouched();
2694
- console.log('Validation failed:', {
2695
- invalid: this.updateUserForm.invalid,
2696
- mismatch: this.updateUserForm.hasError('mismatch'),
2697
- hasChanges: this.hasFormChanged()
2698
- });
2699
2676
  return;
2700
2677
  }
2701
2678
  this.confirmForm.reset();