Skip to content

Commit

Permalink
fix(import,mapping): fix form validation
Browse files Browse the repository at this point in the history
  • Loading branch information
jacquesfize authored and Pierre-Narcisi committed Jan 22, 2025
1 parent bfcf4a7 commit d655a53
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ $icon-size: 19px;

&__button {
$button-disabled-opacity: 0.2;
padding: $icon-size / 4;
padding: calc($icon-size / 4);
height: 2 * $icon-size !important;
width: 2 * $icon-size !important;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -309,7 +309,7 @@ export class FieldMappingService {
.setValidators(
this._formservice.RequiredIfControlIsNotNullValidator(
mandatory_conditions,
this.targetFieldsData.length > 1 ? this.fieldsByEntity.get(entity.label) : []
this.fieldsByEntity.get(entity.label)
)
);
}
Expand All @@ -319,16 +319,14 @@ export class FieldMappingService {
.setValidators(
this._formservice.NotRequiredIfControlIsNotNullValidator(
optional_conditions,
this.targetFieldsData.length > 1 ? this.fieldsByEntity.get(entity.label) : []
this.fieldsByEntity.get(entity.label)
)
);
} else if (mandatory) {
this.mappingFormGroup
.get(name_field)
.setValidators(
this._formservice.NotRequiredIfNoOther(
this.targetFieldsData.length > 1 ? this.fieldsByEntity.get(entity.label) : []
)
this._formservice.NotRequiredIfNoOther(this.fieldsByEntity.get(entity.label))
);
}

Expand Down

0 comments on commit d655a53

Please sign in to comment.