UI: add condition to setter disabled

This commit is contained in:
Artem Dzhereleiko 2023-09-01 11:35:11 +03:00
parent bdc7525ac4
commit f3c7a053ea

View File

@ -101,14 +101,18 @@ export abstract class RuleNodeConfigurationComponent extends PageComponent imple
configurationValue: RuleNodeConfiguration;
private configurationSet = false;
private disabledValue = false;
set disabled(value: boolean) {
if (this.disabledValue !== value) {
this.disabledValue = value;
if (value) {
this.configForm().disable({emitEvent: false});
} else {
this.configForm().enable({emitEvent: false});
this.updateValidators(false);
}
}
};
set configuration(value: RuleNodeConfiguration) {