@trudb/tru-common-lib 0.2.274 → 0.2.275

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.
@@ -7785,16 +7785,8 @@ class TruDataGrid {
7785
7785
  }));
7786
7786
  }
7787
7787
  this.subs.push(this.connectionHub.subscribe(this.dataContext, this.config.resultConfig.entityType, this.config.resultConfig.entityType.name, this.addEntity, this.getRowData, () => { return this.latestSetupQuery; }, this.config.resultConfig.expands, [], () => { return true; }).subscribe((dataChange) => {
7788
- let rowNodesToAdd = [];
7789
7788
  let rowNodesToRemove = [];
7790
7789
  dataChange.dataChanges.forEach((change) => {
7791
- if (change.changeOperation === 'I') {
7792
- this.api.forEachNode((rowNode) => {
7793
- if (rowNode.data.$entity.Ref === change.tableRef) {
7794
- rowNodesToAdd.push(rowNode.data);
7795
- }
7796
- });
7797
- }
7798
7790
  if (change.changeOperation === 'D') {
7799
7791
  this.api.forEachNode((rowNode) => {
7800
7792
  if (rowNode.data.$entity.Ref === change.tableRef) {
@@ -7803,14 +7795,10 @@ class TruDataGrid {
7803
7795
  });
7804
7796
  }
7805
7797
  });
7806
- if (rowNodesToAdd.length) {
7807
- setTimeout(() => {
7808
- this.runSearch();
7809
- }, 100);
7810
- }
7811
7798
  if (rowNodesToRemove.length) {
7812
7799
  this.api.applyTransaction({ remove: rowNodesToRemove });
7813
7800
  }
7801
+ this.api.refreshCells({ force: true });
7814
7802
  }));
7815
7803
  // Listen for entities added elsewhere in the app
7816
7804
  // Merge this logic with addEntity() logic below