@smartbit4all/ng-client 3.3.186 → 3.3.190

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.
Files changed (164) hide show
  1. package/esm2020/lib/session/api/api/session.service.mjs +1 -1
  2. package/esm2020/lib/session/api/encoder.mjs +1 -1
  3. package/esm2020/lib/session/api/model/accountInfo.mjs +1 -1
  4. package/esm2020/lib/session/api/model/apiError.mjs +1 -1
  5. package/esm2020/lib/session/api/model/authenticationProviderData.mjs +1 -1
  6. package/esm2020/lib/session/api/model/getAuthenticationProvidersResponse.mjs +1 -1
  7. package/esm2020/lib/session/api/model/models.mjs +1 -1
  8. package/esm2020/lib/session/api/model/refreshSessionRequest.mjs +1 -1
  9. package/esm2020/lib/session/api/model/session.mjs +1 -1
  10. package/esm2020/lib/session/api/model/sessionInfoData.mjs +1 -1
  11. package/esm2020/lib/session/api/model/userActivityLog.mjs +1 -1
  12. package/esm2020/lib/session/api/param.mjs +1 -1
  13. package/esm2020/lib/session/api/variables.mjs +1 -1
  14. package/esm2020/lib/smart-client/smart-component-api-client.mjs +29 -47
  15. package/esm2020/lib/smart-component-layout/api/api/api.mjs +1 -1
  16. package/esm2020/lib/smart-component-layout/api/api/default.service.mjs +1 -1
  17. package/esm2020/lib/smart-component-layout/api/api.module.mjs +1 -1
  18. package/esm2020/lib/smart-component-layout/api/configuration.mjs +1 -1
  19. package/esm2020/lib/smart-component-layout/api/encoder.mjs +1 -1
  20. package/esm2020/lib/smart-component-layout/api/index.mjs +1 -1
  21. package/esm2020/lib/smart-component-layout/api/model/componentType.mjs +1 -1
  22. package/esm2020/lib/smart-component-layout/api/model/componentWidgetType.mjs +1 -1
  23. package/esm2020/lib/smart-component-layout/api/model/layoutDirection.mjs +1 -1
  24. package/esm2020/lib/smart-component-layout/api/model/models.mjs +1 -1
  25. package/esm2020/lib/smart-component-layout/api/model/smartComponentLayoutDefinition.mjs +1 -1
  26. package/esm2020/lib/smart-component-layout/api/model/smartComponentWidgetDefinition.mjs +1 -1
  27. package/esm2020/lib/smart-component-layout/api/param.mjs +1 -1
  28. package/esm2020/lib/smart-component-layout/api/variables.mjs +1 -1
  29. package/esm2020/lib/smart-filter/api/filter/model/filterExpressionBoolOperator.mjs +1 -1
  30. package/esm2020/lib/smart-filter/api/filter/model/filterExpressionBuilderField.mjs +1 -1
  31. package/esm2020/lib/smart-filter/api/filter/model/filterExpressionBuilderGroup.mjs +1 -1
  32. package/esm2020/lib/smart-filter/api/filter/model/filterExpressionBuilderModel.mjs +1 -1
  33. package/esm2020/lib/smart-filter/api/filter/model/filterExpressionData.mjs +1 -1
  34. package/esm2020/lib/smart-filter/api/filter/model/filterExpressionDataType.mjs +1 -1
  35. package/esm2020/lib/smart-filter/api/filter/model/filterExpressionField.mjs +1 -1
  36. package/esm2020/lib/smart-filter/api/filter/model/filterExpressionFieldList.mjs +1 -1
  37. package/esm2020/lib/smart-filter/api/filter/model/filterExpressionFieldWidgetType.mjs +1 -1
  38. package/esm2020/lib/smart-filter/api/filter/model/filterExpressionList.mjs +1 -1
  39. package/esm2020/lib/smart-filter/api/filter/model/filterExpressionOperandData.mjs +1 -1
  40. package/esm2020/lib/smart-filter/api/filter/model/filterExpressionOperation.mjs +1 -1
  41. package/esm2020/lib/smart-filter/api/filter/model/filterExpressionOrderBy.mjs +1 -1
  42. package/esm2020/lib/smart-filter-editor/api/api/filter.service.mjs +1 -1
  43. package/esm2020/lib/smart-filter-editor/api/configuration.mjs +1 -1
  44. package/esm2020/lib/smart-filter-editor/api/encoder.mjs +1 -1
  45. package/esm2020/lib/smart-filter-editor/api/model/filterExpressionBoolOperator.mjs +1 -1
  46. package/esm2020/lib/smart-filter-editor/api/model/filterExpressionBuilderApiConfig.mjs +1 -1
  47. package/esm2020/lib/smart-filter-editor/api/model/filterExpressionBuilderField.mjs +1 -1
  48. package/esm2020/lib/smart-filter-editor/api/model/filterExpressionBuilderGroup.mjs +1 -1
  49. package/esm2020/lib/smart-filter-editor/api/model/filterExpressionBuilderModel.mjs +1 -1
  50. package/esm2020/lib/smart-filter-editor/api/model/filterExpressionBuilderUiModel.mjs +1 -1
  51. package/esm2020/lib/smart-filter-editor/api/model/filterExpressionData.mjs +1 -1
  52. package/esm2020/lib/smart-filter-editor/api/model/filterExpressionDataType.mjs +1 -1
  53. package/esm2020/lib/smart-filter-editor/api/model/filterExpressionField.mjs +1 -1
  54. package/esm2020/lib/smart-filter-editor/api/model/filterExpressionFieldEditor.mjs +1 -1
  55. package/esm2020/lib/smart-filter-editor/api/model/filterExpressionFieldList.mjs +1 -1
  56. package/esm2020/lib/smart-filter-editor/api/model/filterExpressionFieldWidgetType.mjs +1 -1
  57. package/esm2020/lib/smart-filter-editor/api/model/filterExpressionList.mjs +1 -1
  58. package/esm2020/lib/smart-filter-editor/api/model/filterExpressionOperandData.mjs +1 -1
  59. package/esm2020/lib/smart-filter-editor/api/model/filterExpressionOperation.mjs +1 -1
  60. package/esm2020/lib/smart-filter-editor/api/model/smartFilterType.mjs +1 -1
  61. package/esm2020/lib/smart-filter-editor/api/param.mjs +1 -1
  62. package/esm2020/lib/smart-filter-editor/api/variables.mjs +1 -1
  63. package/esm2020/lib/smart-filter-editor/smart-filter-editor.model.mjs +1 -1
  64. package/esm2020/lib/smart-filter-editor/smart-filter-editor.service.mjs +7 -11
  65. package/esm2020/lib/smart-form/api/api/api.mjs +1 -1
  66. package/esm2020/lib/smart-form/api/api/default.service.mjs +1 -1
  67. package/esm2020/lib/smart-form/api/api.module.mjs +1 -1
  68. package/esm2020/lib/smart-form/api/configuration.mjs +1 -1
  69. package/esm2020/lib/smart-form/api/encoder.mjs +1 -1
  70. package/esm2020/lib/smart-form/api/index.mjs +1 -1
  71. package/esm2020/lib/smart-form/api/model/models.mjs +1 -1
  72. package/esm2020/lib/smart-form/api/model/propertyMapping.mjs +1 -1
  73. package/esm2020/lib/smart-form/api/model/selectionDefinition.mjs +1 -1
  74. package/esm2020/lib/smart-form/api/model/smartFormWidgetDirection.mjs +1 -1
  75. package/esm2020/lib/smart-form/api/model/smartFormWidgetType.mjs +1 -1
  76. package/esm2020/lib/smart-form/api/model/smartLayoutDefinition.mjs +1 -1
  77. package/esm2020/lib/smart-form/api/model/smartWidgetHint.mjs +1 -1
  78. package/esm2020/lib/smart-form/api/model/valueChangeMode.mjs +1 -1
  79. package/esm2020/lib/smart-form/api/param.mjs +1 -1
  80. package/esm2020/lib/smart-form/api/variables.mjs +1 -1
  81. package/esm2020/lib/smart-grid/smart-grid.component.mjs +2 -4
  82. package/esm2020/lib/smart-table/tables/table.mjs +2 -2
  83. package/esm2020/lib/smart-tree/tree-api/api/tree.service.mjs +1 -1
  84. package/esm2020/lib/smart-tree/tree-api/configuration.mjs +1 -1
  85. package/esm2020/lib/smart-tree/tree-api/encoder.mjs +1 -1
  86. package/esm2020/lib/smart-tree/tree-api/param.mjs +1 -1
  87. package/esm2020/lib/smart-tree/tree-api/variables.mjs +1 -1
  88. package/esm2020/lib/view-context/api/api/api.mjs +1 -1
  89. package/esm2020/lib/view-context/api/api/view.service.mjs +1 -1
  90. package/esm2020/lib/view-context/api/api.module.mjs +1 -1
  91. package/esm2020/lib/view-context/api/configuration.mjs +1 -1
  92. package/esm2020/lib/view-context/api/encoder.mjs +1 -1
  93. package/esm2020/lib/view-context/api/index.mjs +1 -1
  94. package/esm2020/lib/view-context/api/model/closeResult.mjs +1 -1
  95. package/esm2020/lib/view-context/api/model/componentConstraint.mjs +1 -1
  96. package/esm2020/lib/view-context/api/model/componentModel.mjs +1 -1
  97. package/esm2020/lib/view-context/api/model/componentModelChange.mjs +1 -1
  98. package/esm2020/lib/view-context/api/model/dataChange.mjs +1 -1
  99. package/esm2020/lib/view-context/api/model/dataChangeEvent.mjs +1 -1
  100. package/esm2020/lib/view-context/api/model/dataChangeKind.mjs +1 -1
  101. package/esm2020/lib/view-context/api/model/downloadedFile.mjs +1 -1
  102. package/esm2020/lib/view-context/api/model/iconPosition.mjs +1 -1
  103. package/esm2020/lib/view-context/api/model/imageResource.mjs +1 -1
  104. package/esm2020/lib/view-context/api/model/link.mjs +1 -1
  105. package/esm2020/lib/view-context/api/model/messageData.mjs +1 -1
  106. package/esm2020/lib/view-context/api/model/messageOption.mjs +1 -1
  107. package/esm2020/lib/view-context/api/model/messageOptionType.mjs +1 -1
  108. package/esm2020/lib/view-context/api/model/messageResult.mjs +1 -1
  109. package/esm2020/lib/view-context/api/model/messageTextType.mjs +1 -1
  110. package/esm2020/lib/view-context/api/model/messageType.mjs +1 -1
  111. package/esm2020/lib/view-context/api/model/models.mjs +1 -1
  112. package/esm2020/lib/view-context/api/model/openPendingData.mjs +1 -1
  113. package/esm2020/lib/view-context/api/model/serverRequestExecutionStat.mjs +1 -1
  114. package/esm2020/lib/view-context/api/model/serverRequestTrack.mjs +1 -1
  115. package/esm2020/lib/view-context/api/model/serverRequestType.mjs +1 -1
  116. package/esm2020/lib/view-context/api/model/smartLinkData.mjs +1 -1
  117. package/esm2020/lib/view-context/api/model/statisticRecord.mjs +1 -1
  118. package/esm2020/lib/view-context/api/model/style.mjs +1 -1
  119. package/esm2020/lib/view-context/api/model/uiAction.mjs +1 -1
  120. package/esm2020/lib/view-context/api/model/uiActionButtonDescriptor.mjs +1 -1
  121. package/esm2020/lib/view-context/api/model/uiActionButtonType.mjs +1 -1
  122. package/esm2020/lib/view-context/api/model/uiActionConstraint.mjs +1 -1
  123. package/esm2020/lib/view-context/api/model/uiActionDescriptor.mjs +1 -1
  124. package/esm2020/lib/view-context/api/model/uiActionDialogDescriptor.mjs +1 -1
  125. package/esm2020/lib/view-context/api/model/uiActionFeedbackType.mjs +1 -1
  126. package/esm2020/lib/view-context/api/model/uiActionInputType.mjs +1 -1
  127. package/esm2020/lib/view-context/api/model/uiActionRequest.mjs +1 -1
  128. package/esm2020/lib/view-context/api/model/uiActionTooltip.mjs +1 -1
  129. package/esm2020/lib/view-context/api/model/uiActionUploadDescriptor.mjs +1 -1
  130. package/esm2020/lib/view-context/api/model/valueSet.mjs +1 -1
  131. package/esm2020/lib/view-context/api/model/view.mjs +1 -1
  132. package/esm2020/lib/view-context/api/model/viewApiError.mjs +1 -1
  133. package/esm2020/lib/view-context/api/model/viewConstraint.mjs +1 -1
  134. package/esm2020/lib/view-context/api/model/viewContext.mjs +1 -1
  135. package/esm2020/lib/view-context/api/model/viewContextChange.mjs +1 -1
  136. package/esm2020/lib/view-context/api/model/viewContextData.mjs +1 -1
  137. package/esm2020/lib/view-context/api/model/viewContextUpdate.mjs +1 -1
  138. package/esm2020/lib/view-context/api/model/viewData.mjs +1 -1
  139. package/esm2020/lib/view-context/api/model/viewState.mjs +1 -1
  140. package/esm2020/lib/view-context/api/model/viewStateUpdate.mjs +1 -1
  141. package/esm2020/lib/view-context/api/model/viewType.mjs +1 -1
  142. package/esm2020/lib/view-context/api/param.mjs +1 -1
  143. package/esm2020/lib/view-context/api/variables.mjs +1 -1
  144. package/esm2020/lib/view-context/smart-view-context.service.mjs +22 -31
  145. package/esm2020/lib/view-context/value-api/model/genericValue.mjs +1 -1
  146. package/esm2020/lib/view-context/value-api/model/models.mjs +1 -1
  147. package/esm2020/lib/view-context/value-api/model/valueSetDefinitionIdentifier.mjs +1 -1
  148. package/fesm2015/smartbit4all-ng-client.mjs +60 -92
  149. package/fesm2015/smartbit4all-ng-client.mjs.map +1 -1
  150. package/fesm2020/smartbit4all-ng-client.mjs +57 -90
  151. package/fesm2020/smartbit4all-ng-client.mjs.map +1 -1
  152. package/lib/smart-client/smart-component-api-client.d.ts +1 -1
  153. package/lib/smart-filter-editor/smart-filter-editor.model.d.ts +1 -1
  154. package/lib/smart-grid/smart-grid.component.d.ts +1 -1
  155. package/lib/view-context/smart-view-context.service.d.ts +3 -4
  156. package/package.json +1 -1
  157. package/smartbit4all-ng-client-3.3.190.tgz +0 -0
  158. package/src/lib/session/api/README.md +226 -226
  159. package/src/lib/smart-component-layout/api/README.md +226 -226
  160. package/src/lib/smart-filter-editor/api/README.md +226 -226
  161. package/src/lib/smart-form/api/README.md +226 -226
  162. package/src/lib/smart-tree/tree-api/README.md +226 -226
  163. package/src/lib/view-context/api/README.md +226 -226
  164. package/smartbit4all-ng-client-3.3.186.tgz +0 -0
@@ -2704,9 +2704,10 @@ class SmartViewContextService {
2704
2704
  });
2705
2705
  }
2706
2706
  openView(view) {
2707
+ var _a;
2707
2708
  let alreadyOpened = this.openedViewUuids.some((uuid) => uuid === view.uuid);
2708
2709
  if (alreadyOpened)
2709
- return undefined;
2710
+ return;
2710
2711
  let viewHandler = this.viewHandlers.find((handler) => handler.name === view.viewName);
2711
2712
  if (!viewHandler) {
2712
2713
  throw new Error(`SmartViewHandlerModel was not found by view name: ${view.viewName}`);
@@ -2739,7 +2740,7 @@ class SmartViewContextService {
2739
2740
  try {
2740
2741
  dialogDisableClose = this.inject.get(DIALOG_DISABLE_CLOSE);
2741
2742
  }
2742
- catch (_a) {
2743
+ catch (_b) {
2743
2744
  console.error('Error during reading DIALOG_DISABLE_CLOSE');
2744
2745
  }
2745
2746
  }
@@ -2776,12 +2777,18 @@ class SmartViewContextService {
2776
2777
  this.openedViewData.push(view);
2777
2778
  this.setUuidOfPage(view.viewName, view.uuid, viewHandler.componentName);
2778
2779
  this.uuidOfPageHasBeenChanged.next(view.viewName);
2779
- return {
2780
- state: ViewState.OPENED,
2781
- uuid: view.uuid,
2782
- };
2780
+ this.updateViewContext({
2781
+ updates: [
2782
+ {
2783
+ state: ViewState.OPENED,
2784
+ uuid: view.uuid,
2785
+ },
2786
+ ],
2787
+ uuid: (_a = this.viewContext) === null || _a === void 0 ? void 0 : _a.uuid,
2788
+ });
2783
2789
  }
2784
2790
  closeView(view) {
2791
+ var _a;
2785
2792
  let viewHandler = this.viewHandlers.find((handler) => handler.name === view.viewName);
2786
2793
  if (!viewHandler) {
2787
2794
  throw new Error(`SmartViewHandlerModel was not found by view name: ${view.viewName}`);
@@ -2811,51 +2818,37 @@ class SmartViewContextService {
2811
2818
  this.openedViewData.splice(index, 1);
2812
2819
  this.clearUuidOfPage(view.viewName, viewHandler.componentName);
2813
2820
  }
2814
- return {
2815
- state: ViewState.CLOSED,
2816
- uuid: view.uuid,
2817
- };
2818
- }
2819
- updateContext(updates) {
2820
- var _a;
2821
2821
  this.updateViewContext({
2822
- updates,
2822
+ updates: [
2823
+ {
2824
+ state: ViewState.CLOSED,
2825
+ uuid: view.uuid,
2826
+ },
2827
+ ],
2823
2828
  uuid: (_a = this.viewContext) === null || _a === void 0 ? void 0 : _a.uuid,
2824
2829
  });
2825
2830
  }
2826
2831
  restoreViews(uuid) {
2827
2832
  return __awaiter(this, void 0, void 0, function* () {
2828
- const updates = [];
2829
2833
  if (!this.viewContext) {
2830
2834
  yield this.getViewContext(uuid);
2831
2835
  }
2832
- this.viewContext.views.filter((view) => view.state === ViewState.OPENED || view.state === ViewState.TO_OPEN).map((view) => {
2833
- const update = this.openView(view);
2834
- if (update) {
2835
- updates.push(update);
2836
- }
2836
+ this.viewContext.views.map((view) => {
2837
+ this.openView(view);
2837
2838
  });
2838
- if (updates.length > 0) {
2839
- this.updateContext(updates);
2840
- }
2841
2839
  });
2842
2840
  }
2843
2841
  syncView() {
2844
2842
  var _a, _b, _c, _d, _e;
2845
- const updates = [];
2846
2843
  (_a = this.viewContext) === null || _a === void 0 ? void 0 : _a.views.map((view) => {
2847
- let update = undefined;
2848
2844
  switch (view.state) {
2849
2845
  case ViewState.TO_OPEN:
2850
- update = this.openView(view);
2846
+ this.openView(view);
2851
2847
  break;
2852
2848
  case ViewState.TO_CLOSE:
2853
- update = this.closeView(view);
2849
+ this.closeView(view);
2854
2850
  break;
2855
2851
  }
2856
- if (update) {
2857
- updates.push(update);
2858
- }
2859
2852
  });
2860
2853
  const viewDataToClose = this.openedViewData.filter((viewData) => {
2861
2854
  var _a;
@@ -2863,10 +2856,9 @@ class SmartViewContextService {
2863
2856
  });
2864
2857
  if (viewDataToClose === null || viewDataToClose === void 0 ? void 0 : viewDataToClose.length) {
2865
2858
  viewDataToClose.map((viewData) => {
2866
- updates.push(this.closeView(viewData));
2859
+ this.closeView(viewData);
2867
2860
  });
2868
2861
  }
2869
- this.updateContext(updates);
2870
2862
  (_c = (_b = this.viewContext) === null || _b === void 0 ? void 0 : _b.links) === null || _c === void 0 ? void 0 : _c.map((data) => {
2871
2863
  var _a, _b;
2872
2864
  const link = document.createElement('a');
@@ -6677,7 +6669,7 @@ class Table {
6677
6669
  }
6678
6670
  customButtonClicked(event, button, element, btn, close) {
6679
6671
  event.stopPropagation();
6680
- if (btn.disabled) {
6672
+ if (btn === null || btn === void 0 ? void 0 : btn.disabled) {
6681
6673
  return;
6682
6674
  }
6683
6675
  if (button.type === SmartTableButtonType.MENU && btn === undefined)
@@ -10282,9 +10274,7 @@ class SmartGridComponent {
10282
10274
  return __awaiter(this, void 0, void 0, function* () {
10283
10275
  this.setupToolbar();
10284
10276
  // will cause this.service.gridModelChanged to fire
10285
- if (this.uuid) {
10286
- yield this.service.load(this.uuid, this.smartGrid.gridIdentifier);
10287
- }
10277
+ yield this.service.load(this.uuid, this.smartGrid.gridIdentifier);
10288
10278
  });
10289
10279
  }
10290
10280
  setupToolbar() {
@@ -15309,20 +15299,16 @@ class SmartFilterEditorService {
15309
15299
  }
15310
15300
  load() {
15311
15301
  return __awaiter(this, void 0, void 0, function* () {
15312
- if (this.config.uuid) {
15313
- this.model = yield this.service.load(this.config.uuid, this.config.identifier).toPromise();
15314
- this.modelChanged.next();
15315
- }
15302
+ this.model = yield this.service.load(this.config.uuid, this.config.identifier).toPromise();
15303
+ this.modelChanged.next();
15316
15304
  });
15317
15305
  }
15318
15306
  peformWidgetAction(request) {
15319
15307
  return __awaiter(this, void 0, void 0, function* () {
15320
- if (this.config.uuid) {
15321
- this.model = yield this.service
15322
- .performWidgetAction(this.config.uuid, this.config.identifier, request)
15323
- .toPromise();
15324
- this.modelChanged.next();
15325
- }
15308
+ this.model = yield this.service
15309
+ .performWidgetAction(this.config.uuid, this.config.identifier, request)
15310
+ .toPromise();
15311
+ this.modelChanged.next();
15326
15312
  });
15327
15313
  }
15328
15314
  getModel() {
@@ -15361,7 +15347,7 @@ class SmartComponentApiClient {
15361
15347
  this.renderer = renderer;
15362
15348
  this._destroy$ = new Subject();
15363
15349
  this.detectChange = new SmartSubject(this._destroy$);
15364
- this.componentModelLoaded = false;
15350
+ this._ngAfterViewInitPerformed = false;
15365
15351
  this.uiActionModels = [];
15366
15352
  this.dataChanged = new SmartSubject(this._destroy$);
15367
15353
  // Contained Widgets
@@ -15405,29 +15391,29 @@ class SmartComponentApiClient {
15405
15391
  firstUuid = false;
15406
15392
  }
15407
15393
  this._uuid = uuid;
15408
- this.getWidgets().forEach((ref, key) => {
15409
- if (ref instanceof SmartGridComponent) {
15410
- ref.uuid = this.componentModelLoaded ? uuid : undefined;
15411
- }
15412
- else if (ref instanceof SmartFilterEditorService) {
15413
- ref.config.uuid = this.componentModelLoaded ? uuid : undefined;
15414
- }
15415
- else if (!ref && !firstUuid) {
15416
- console.error(`Provided reference for ${key} is undefined on uuid change.`);
15417
- }
15418
- });
15419
- if (!this.uuidOfPageHasBeenChangedSubscription) {
15420
- this.uuidOfPageHasBeenChangedSubscription = this.viewContext.uuidOfPageHasBeenChanged
15421
- .pipe(takeUntil(this._destroy$))
15422
- .subscribe((pageName) => {
15423
- if (pageName === this.pageName) {
15424
- this.run();
15394
+ if (uuid) {
15395
+ this.getWidgets().forEach((ref, key) => {
15396
+ if (ref instanceof SmartGridComponent) {
15397
+ ref.uuid = uuid;
15398
+ }
15399
+ else if (ref instanceof SmartFilterEditorService) {
15400
+ ref.config.uuid = uuid;
15401
+ }
15402
+ else if (!ref && !firstUuid) {
15403
+ console.error(`Provided reference for ${key} is undefined on uuid change.`);
15425
15404
  }
15426
15405
  });
15406
+ if (!this.uuidOfPageHasBeenChangedSubscription) {
15407
+ this.uuidOfPageHasBeenChangedSubscription = this.viewContext.uuidOfPageHasBeenChanged
15408
+ .pipe(takeUntil(this._destroy$))
15409
+ .subscribe((pageName) => {
15410
+ if (pageName === this.pageName) {
15411
+ this.run();
15412
+ }
15413
+ });
15414
+ }
15427
15415
  }
15428
- if (uuid) {
15429
- this.viewContext.follow(this._uuid, this.detectChange);
15430
- }
15416
+ this.viewContext.follow(this._uuid, this.detectChange);
15431
15417
  }
15432
15418
  get model() {
15433
15419
  return this._model;
@@ -15664,17 +15650,9 @@ class SmartComponentApiClient {
15664
15650
  }
15665
15651
  load() {
15666
15652
  return __awaiter(this, void 0, void 0, function* () {
15667
- this.componentModelLoaded = false;
15668
- const uuid = this.viewContext.getUuidOfPage(this.pageName);
15653
+ this.uuid = this.viewContext.getUuidOfPage(this.pageName);
15669
15654
  // this.model = await this.viewContext.load(this.uuid);
15670
- const change = yield this.viewContext.load2(uuid);
15671
- this.componentModelLoaded = true;
15672
- this.uuid = uuid;
15673
- this.model = change.result;
15674
- if (this.model.widgets) {
15675
- // grids are already loaded in setUuid()
15676
- this.handleChangeWidgets(this.model.widgets, true);
15677
- }
15655
+ yield this.viewContext.load2(this.uuid);
15678
15656
  });
15679
15657
  }
15680
15658
  executeUiAction(uiAction, options) {
@@ -15925,10 +15903,6 @@ class SmartComponentApiClient {
15925
15903
  }
15926
15904
  handleChanges(change) {
15927
15905
  try {
15928
- if (!this.componentModelLoaded) {
15929
- // initial load
15930
- return;
15931
- }
15932
15906
  if (change.changedWidgets) {
15933
15907
  this.handleChangeWidgets(change.changedWidgets);
15934
15908
  }
@@ -15973,27 +15947,21 @@ class SmartComponentApiClient {
15973
15947
  this.model = change.value;
15974
15948
  }
15975
15949
  }
15976
- handleChangeWidgets(changedWidgets, skipLoad = false) {
15950
+ handleChangeWidgets(changedWidgets) {
15977
15951
  let widgets = this.getWidgets();
15978
15952
  changedWidgets.forEach((key) => {
15979
15953
  const reference = widgets.get(key);
15980
15954
  if (reference instanceof SmartGridComponent) {
15981
15955
  this.setupGridServices(reference);
15982
- if (!skipLoad) {
15983
- reference.refresh();
15984
- }
15956
+ reference.refresh();
15985
15957
  }
15986
15958
  else if (reference instanceof SmarttreeGenericService) {
15987
- if (!skipLoad) {
15988
- reference.initialize();
15989
- }
15959
+ reference.initialize();
15990
15960
  }
15991
15961
  else if (reference instanceof SmartFilterEditorService) {
15992
- if (!skipLoad) {
15993
- reference.load();
15994
- }
15962
+ reference.load();
15995
15963
  }
15996
- else if (!skipLoad && reference === undefined) {
15964
+ else if (reference === undefined) {
15997
15965
  console.error(`Provided reference for ${key} is undefined.`);
15998
15966
  }
15999
15967
  });