@smartbit4all/ng-client 3.1.70 → 3.1.71

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.
@@ -13032,6 +13032,18 @@ class SmartFilterEditorContentComponent {
13032
13032
  this.expressionUiActionModels = [];
13033
13033
  this.type = FilterExpressionBuilderUiModel.TypeEnum;
13034
13034
  }
13035
+ ngAfterViewInit() {
13036
+ if (this.smartFilterChild) {
13037
+ this.smartFilterChild.service.change.pipe(takeUntil(this._destroy$)).subscribe(() => {
13038
+ this.saveFilter();
13039
+ });
13040
+ }
13041
+ if (this.formChild) {
13042
+ this.formChild.onBlurSubject?.pipe(takeUntil(this._destroy$)).subscribe(() => {
13043
+ this.save();
13044
+ });
13045
+ }
13046
+ }
13035
13047
  ngOnInit() {
13036
13048
  this.service.load();
13037
13049
  this.service.modelChanged.pipe(takeUntil(this._destroy$)).subscribe(() => {
@@ -13044,14 +13056,11 @@ class SmartFilterEditorContentComponent {
13044
13056
  }
13045
13057
  setupSimpleFilter() { }
13046
13058
  setUp() {
13047
- if (this.service.model?.type === this.type.Simple && !this.smartFilterChild) {
13059
+ if (this.service.model?.type === this.type.Simple) {
13048
13060
  this.simpleFilterModel = {
13049
13061
  data: this.service.model.model.workplaceList.filters,
13050
13062
  type: SmartFilterType.SIMPLE,
13051
13063
  };
13052
- this.smartFilterChild.service.change.pipe(takeUntil(this._destroy$)).subscribe(() => {
13053
- this.saveFilter();
13054
- });
13055
13064
  }
13056
13065
  else {
13057
13066
  this.constructUiActionModels();
@@ -13089,8 +13098,6 @@ class SmartFilterEditorContentComponent {
13089
13098
  }
13090
13099
  }
13091
13100
  constructForm() {
13092
- if (this.formChild)
13093
- return;
13094
13101
  let generatedWidgets = this.layoutService.render({
13095
13102
  layoutDefinitions: this.service.model?.selectedFieldEditor?.layoutDef?.widgets,
13096
13103
  });
@@ -13100,9 +13107,6 @@ class SmartFilterEditorContentComponent {
13100
13107
  componentModel: { data: this.service.model?.selectedField },
13101
13108
  widgets: generatedWidgets,
13102
13109
  };
13103
- this.formChild.onBlurSubject?.pipe(takeUntil(this._destroy$)).subscribe(() => {
13104
- this.save();
13105
- });
13106
13110
  }
13107
13111
  save() {
13108
13112
  this.formChild?.submitForm(false);