dbgate-datalib 5.0.6-alpha.2 → 5.0.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.
@@ -95,6 +95,7 @@ export declare abstract class GridDisplay {
95
95
  isSortDefined(): boolean;
96
96
  get filterCount(): number;
97
97
  clearFilters(): void;
98
+ resetConfig(): void;
98
99
  getChangeSetCondition(row: any): Pick<any, string>;
99
100
  getChangeSetField(row: any, uniqueName: any, insertedRowIndex: any): ChangeSetFieldDefinition;
100
101
  getChangeSetRow(row: any, insertedRowIndex: any): ChangeSetRowDefinition;
@@ -116,12 +116,14 @@ class GridDisplay {
116
116
  const condition = (0, dbgate_filterparser_1.parseFilter)(filter, (0, dbgate_filterparser_1.getFilterType)(column.dataType));
117
117
  if (condition) {
118
118
  conditions.push(lodash_1.default.cloneDeepWith(condition, (expr) => {
119
- if (expr.exprType == 'placeholder')
120
- return {
121
- exprType: 'column',
122
- columnName: column.columnName,
123
- source: { alias: column.sourceAlias },
124
- };
119
+ if (expr.exprType == 'placeholder') {
120
+ return this.createColumnExpression(column, { alias: column.sourceAlias });
121
+ }
122
+ // return {
123
+ // exprType: 'column',
124
+ // columnName: column.columnName,
125
+ // source: { alias: column.sourceAlias },
126
+ // };
125
127
  }));
126
128
  }
127
129
  }
@@ -307,6 +309,10 @@ class GridDisplay {
307
309
  this.setConfig(cfg => (Object.assign(Object.assign({}, cfg), { filters: {} })));
308
310
  this.reload();
309
311
  }
312
+ resetConfig() {
313
+ this.setConfig(cfg => (0, GridConfig_1.createGridConfig)());
314
+ this.reload();
315
+ }
310
316
  getChangeSetCondition(row) {
311
317
  if (!this.changeSetKeyFields)
312
318
  return null;
package/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "5.0.6-alpha.2",
2
+ "version": "5.0.8",
3
3
  "name": "dbgate-datalib",
4
4
  "main": "lib/index.js",
5
5
  "typings": "lib/index.d.ts",
@@ -11,11 +11,11 @@
11
11
  "lib"
12
12
  ],
13
13
  "dependencies": {
14
- "dbgate-sqltree": "^5.0.6-alpha.2",
15
- "dbgate-filterparser": "^5.0.6-alpha.2"
14
+ "dbgate-sqltree": "^5.0.8",
15
+ "dbgate-filterparser": "^5.0.8"
16
16
  },
17
17
  "devDependencies": {
18
- "dbgate-types": "^5.0.6-alpha.2",
18
+ "dbgate-types": "^5.0.8",
19
19
  "@types/node": "^13.7.0",
20
20
  "typescript": "^4.4.3"
21
21
  }