Dataset template editor: On multiplicity changed, reset multiplicity values including table view and placeholder.

This commit is contained in:
Konstantinos Triantafyllou 2023-04-20 16:01:21 +03:00
parent ef0816524f
commit 681f73b865
1 changed files with 6 additions and 0 deletions

View File

@ -360,13 +360,19 @@ export class DatasetProfileEditorCompositeFieldComponent extends BaseComponent i
const minControl = multiplicity.get('min');
const maxControl = multiplicity.get('max');
const placeholder = multiplicity.get('placeholder');
const tableView = multiplicity.get('tableView');
if (isMultiplicityEnabled.checked) {
minControl.setValue(0);
maxControl.setValue(1);
placeholder.setValue('');
tableView.setValue(false);
}else{
minControl.setValue(0);
maxControl.setValue(0);
placeholder.setValue(null);
tableView.setValue(null);
}
this.isMultiplicityEnabled = isMultiplicityEnabled.checked;