ngx-rs-ant 0.9.6 → 0.9.8

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.
@@ -895,12 +895,12 @@ class DataGridComponent {
895
895
  this.reload();
896
896
  }
897
897
  reload() {
898
- this.dxDataGrid.instance?.state(null);
898
+ this.columns.length = 0;
899
899
  this.service.getMetadataByView(this.tenant, this.className, this.view || '').subscribe((response) => {
900
- this.columns = [];
900
+ const columns = [];
901
901
  for (let field of response.data.columns) {
902
902
  if (field.type === 'FILE') {
903
- this.columns.push({
903
+ columns.push({
904
904
  dataField: field.name,
905
905
  caption: field.caption,
906
906
  dataType: 'string',
@@ -924,7 +924,7 @@ class DataGridComponent {
924
924
  format: this.typeMap[field.dataType].format,
925
925
  visible: field.visible
926
926
  };
927
- this.columns.push(column);
927
+ columns.push(column);
928
928
  switch (field.dataType) {
929
929
  case 'BOOLEAN':
930
930
  column.allowHeaderFiltering = false;
@@ -1131,7 +1131,7 @@ class DataGridComponent {
1131
1131
  }
1132
1132
  }
1133
1133
  else if (field.type === 'RELATION') {
1134
- this.columns.push({
1134
+ columns.push({
1135
1135
  dataField: field.name,
1136
1136
  caption: field.caption,
1137
1137
  dataType: 'string',
@@ -1143,8 +1143,9 @@ class DataGridComponent {
1143
1143
  }
1144
1144
  }
1145
1145
  if (this.customColumnFn) {
1146
- this.customColumnFn(this.columns);
1146
+ this.customColumnFn(columns);
1147
1147
  }
1148
+ this.columns = columns;
1148
1149
  });
1149
1150
  this.dataSource = new CustomStore({
1150
1151
  key: 'oid',