@genesislcap/grid-pro 14.147.1-alpha-e9dbeac.0 → 14.148.0

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.
@@ -7934,7 +7934,8 @@
7934
7934
  },
7935
7935
  {
7936
7936
  "kind": "method",
7937
- "name": "dataLogoff"
7937
+ "name": "dataLogoff",
7938
+ "privacy": "private"
7938
7939
  },
7939
7940
  {
7940
7941
  "kind": "method",
@@ -7954,42 +7955,6 @@
7954
7955
  }
7955
7956
  ]
7956
7957
  },
7957
- {
7958
- "kind": "method",
7959
- "name": "getAvailableIndexes",
7960
- "privacy": "private",
7961
- "return": {
7962
- "type": {
7963
- "text": "string[]"
7964
- }
7965
- },
7966
- "parameters": [
7967
- {
7968
- "name": "data",
7969
- "type": {
7970
- "text": "Map<string, [string]>"
7971
- }
7972
- }
7973
- ]
7974
- },
7975
- {
7976
- "kind": "method",
7977
- "name": "getAvailableIndexFields",
7978
- "privacy": "private",
7979
- "return": {
7980
- "type": {
7981
- "text": "string[]"
7982
- }
7983
- },
7984
- "parameters": [
7985
- {
7986
- "name": "data",
7987
- "type": {
7988
- "text": "Map<string, [string]>"
7989
- }
7990
- }
7991
- ]
7992
- },
7993
7958
  {
7994
7959
  "kind": "method",
7995
7960
  "name": "handleCurrentStreamLoad",
@@ -8185,11 +8150,11 @@
8185
8150
  },
8186
8151
  {
8187
8152
  "kind": "method",
8188
- "name": "deinit"
8153
+ "name": "init"
8189
8154
  },
8190
8155
  {
8191
8156
  "kind": "method",
8192
- "name": "init"
8157
+ "name": "reset"
8193
8158
  },
8194
8159
  {
8195
8160
  "kind": "method",
@@ -8198,13 +8163,7 @@
8198
8163
  {
8199
8164
  "kind": "method",
8200
8165
  "name": "clearRowData",
8201
- "privacy": "private",
8202
- "parameters": [
8203
- {
8204
- "name": "withColumnDefs",
8205
- "default": "true"
8206
- }
8207
- ]
8166
+ "privacy": "private"
8208
8167
  },
8209
8168
  {
8210
8169
  "kind": "method",
@@ -53,11 +53,9 @@ export declare class StreamDatasource extends StreamBaseDatasource implements IS
53
53
  constructor(options: StreamDatasourceOptions);
54
54
  getRows(params: IServerSideGetRowsParams): Promise<void>;
55
55
  private sortMapByNumericKey;
56
- dataLogoff(): void;
56
+ private dataLogoff;
57
57
  private restartSubscription;
58
58
  private getOrderByAndToBeSortedColIds;
59
- private getAvailableIndexes;
60
- private getAvailableIndexFields;
61
59
  private handleCurrentStreamLoad;
62
60
  private buildCriteriaMatchFromFilters;
63
61
  private criteriaFromFilters;
@@ -214,6 +212,11 @@ declare const GridProServerSideDatasource_base: (new (...args: any[]) => {
214
212
  readonly DOCUMENT_TYPE_NODE: number;
215
213
  readonly ELEMENT_NODE: number;
216
214
  readonly ENTITY_NODE: number;
215
+ /**
216
+ * A Genesis Datasource element, for server-side | SSRM-compatible data fetching and used exclusively by the GridPro element.
217
+ * @remarks Only supports Server-Side Row Model. Requires `@ag-grid-enterprise/server-side-row-model` setup and valid AG Grid Enterprise license.
218
+ * @alpha
219
+ */
217
220
  readonly ENTITY_REFERENCE_NODE: number;
218
221
  readonly NOTATION_NODE: number;
219
222
  readonly PROCESSING_INSTRUCTION_NODE: number;
@@ -258,11 +261,7 @@ declare const GridProServerSideDatasource_base: (new (...args: any[]) => {
258
261
  ariaValueMin: string;
259
262
  ariaValueNow: string;
260
263
  ariaValueText: string;
261
- role: string; /**
262
- * A Genesis Datasource element, for server-side | SSRM-compatible data fetching and used exclusively by the GridPro element.
263
- * @remarks Only supports Server-Side Row Model. Requires `@ag-grid-enterprise/server-side-row-model` setup and valid AG Grid Enterprise license.
264
- * @alpha
265
- */
264
+ role: string;
266
265
  animate(keyframes: PropertyIndexedKeyframes | Keyframe[], options?: number | KeyframeAnimationOptions): Animation;
267
266
  getAnimations(options?: GetAnimationsOptions): Animation[];
268
267
  after(...nodes: (string | Node)[]): void;
@@ -401,12 +400,6 @@ export declare class GridProServerSideDatasource extends GridProServerSideDataso
401
400
  applyFuncName: string;
402
401
  applyAsyncFuncName: string;
403
402
  criteriaChanged(oldCriteria: string, newCriteria: string): void;
404
- /**
405
- * Resets the grid data while keeping columnDefs and sends a DATA_LOGOFF message if it's a stream.
406
- * @remarks This is used when the grid is already initialized and we want to reload the data due to a criteria/filter change.
407
- * @internal
408
- */
409
- private reloadResourceData;
410
403
  resourceNameChanged(oldValue: string, newValue: string): void;
411
404
  pagination: boolean;
412
405
  private indexes;
@@ -415,8 +408,8 @@ export declare class GridProServerSideDatasource extends GridProServerSideDataso
415
408
  connectedCallback(): void;
416
409
  disconnectedCallback(): void;
417
410
  deepClone(): Node;
418
- deinit(): void;
419
411
  init(): void;
412
+ reset(): void;
420
413
  restart(): void;
421
414
  private clearRowData;
422
415
  private getResourceIndexes;
@@ -1 +1 @@
1
- {"version":3,"file":"server-side.datasource.d.ts","sourceRoot":"","sources":["../../../src/datasource/server-side.datasource.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAGV,qBAAqB,EACrB,wBAAwB,EACxB,mBAAmB,EAEnB,kBAAkB,EAClB,2BAA2B,EAG5B,MAAM,yBAAyB,CAAC;AACjC,OAAO,EACL,IAAI,EACJ,OAAO,EAKP,wBAAwB,EAIxB,cAAc,EAGd,gBAAgB,EAEjB,MAAM,+BAA+B,CAAC;AAQvC,OAAO,EAAE,qBAAqB,EAAE,oBAAoB,EAAE,MAAM,mBAAmB,CAAC;AAOhF;;;;;GAKG;AACH,MAAM,MAAM,uBAAuB,GAAG;IACpC,MAAM,EAAE,gBAAgB,CAAC,wBAAwB,CAAC,CAAC;IACnD,YAAY,EAAE,MAAM,CAAC;IACrB,cAAc,CAAC,EAAE,GAAG,CAAC;IACrB,eAAe,CAAC,EAAE,GAAG,CAAC,MAAM,EAAE,CAAC,MAAM,CAAC,CAAC,CAAC;IACxC,eAAe,CAAC,EAAE,cAAc,EAAE,CAAC;IAEnC,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,KAAK,CAA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,SAAS,IAAI,IAAI;IAO1B,IAAI;IAsEJ,KAAK;IAOL,OAAO;IAKP,OAAO,CAAC,YAAY;IAWpB,OAAO,CAAC,kBAAkB;IAU1B,IAAI,MAAM,QA2BT;IAED,IAAI,QAAQ,IAAI,mBAAmB,CAElC;YAEa,sBAAsB;IAoCpC,OAAO,CAAC,uBAAuB;IAU/B,OAAO,CAAC,eAAe;IA6Dd,gBAAgB,CAAC,aAAa,EAAE,kBAAkB,GAAG,2BAA2B;IAIhF,qBAAqB,CAC5B,aAAa,EAAE,kBAAkB,EACjC,QAAQ,CAAC,EAAE,CAAC,GAAG,EAAE,2BAA2B,KAAK,IAAI;CAIxD"}
@@ -72,21 +72,12 @@ export class StreamDatasource extends StreamBaseDatasource {
72
72
  const coldIdBeingSorted = this.currentSortModel[0].colId; // Not allowing multiple sorts by user
73
73
  const sortTypeBeingApplied = this.currentSortModel[0].sort;
74
74
  const orderByAndToBeSortedColIds = this.getOrderByAndToBeSortedColIds(this.resourceIndexes, coldIdBeingSorted);
75
- if (!orderByAndToBeSortedColIds) {
76
- const availableIndexes = this.getAvailableIndexes(this.resourceIndexes);
77
- const availableIndexFields = this.getAvailableIndexFields(this.resourceIndexes);
78
- logger.warn('The FIELD/column (${coldIdBeingSorted}) being sorted is not part of an INDEX, required for the [orderBy] operation. See https://learn.genesis.global/docs/database/data-types/index-entities/');
79
- logger.debug('Available indexes:', availableIndexes);
80
- logger.debug('Columns that can be sorted with the available indexes:', availableIndexFields);
81
- }
82
- else {
83
- orderByAndToBeSortedColIds.toBeSorted.forEach((colId) => {
84
- this.currentSortModel.push({ sort: sortTypeBeingApplied, colId });
85
- });
86
- this.resourceParams.ORDER_BY = orderByAndToBeSortedColIds.orderBy;
87
- this.resourceParams.REVERSE = sortTypeBeingApplied === 'desc' ? true : false;
88
- this.restartSubscription();
89
- }
75
+ orderByAndToBeSortedColIds.toBeSorted.forEach((colId) => {
76
+ this.currentSortModel.push({ sort: sortTypeBeingApplied, colId });
77
+ });
78
+ this.resourceParams.ORDER_BY = orderByAndToBeSortedColIds.orderBy;
79
+ this.resourceParams.REVERSE = sortTypeBeingApplied === 'desc' ? true : false;
80
+ this.restartSubscription();
90
81
  }
91
82
  }
92
83
  if (this.moreRows && params.request.startRow >= Number(this.maxRows)) {
@@ -172,31 +163,6 @@ export class StreamDatasource extends StreamBaseDatasource {
172
163
  }
173
164
  }
174
165
  }
175
- getAvailableIndexes(data) {
176
- const availabeIndexes = [];
177
- for (const [key] of data) {
178
- if (key) {
179
- availabeIndexes.push(key);
180
- }
181
- }
182
- return availabeIndexes;
183
- }
184
- getAvailableIndexFields(data) {
185
- const innermostValues = [];
186
- function traverse(items) {
187
- for (const item of items) {
188
- if (item !== null) {
189
- innermostValues.push(item);
190
- }
191
- }
192
- }
193
- for (const [key, value] of data) {
194
- if (key !== null && value !== null) {
195
- traverse(value);
196
- }
197
- }
198
- return innermostValues;
199
- }
200
166
  handleCurrentStreamLoad(result) {
201
167
  var _a;
202
168
  if (!result)
@@ -287,7 +253,6 @@ __decorate([
287
253
  Connect
288
254
  ], StreamDatasource.prototype, "connect", void 0);
289
255
  const criteriaDelimiter = ';';
290
- const withoutColumnDefs = null;
291
256
  /**
292
257
  * A Genesis Datasource element, for server-side | SSRM-compatible data fetching and used exclusively by the GridPro element.
293
258
  * @remarks Only supports Server-Side Row Model. Requires `@ag-grid-enterprise/server-side-row-model` setup and valid AG Grid Enterprise license.
@@ -301,27 +266,14 @@ let GridProServerSideDatasource = class GridProServerSideDatasource extends Life
301
266
  this.pagination = false;
302
267
  }
303
268
  criteriaChanged(oldCriteria, newCriteria) {
304
- const criteriaIsNotDuplicate = oldCriteria !== normaliseCriteria(newCriteria, criteriaDelimiter);
305
- if (this.ssrmDatasource && criteriaIsNotDuplicate) {
306
- this.reloadResourceData();
269
+ const startingCriteria = !oldCriteria && newCriteria;
270
+ const criteriaNotDuplicate = oldCriteria !== normaliseCriteria(newCriteria, criteriaDelimiter);
271
+ // TODO: FUI-1323 - account for linked grid scenarios too.
272
+ // TODO: check grid-pro-genesis-datasource criteriaChanged
273
+ if (!startingCriteria && criteriaNotDuplicate) {
274
+ this.restart();
307
275
  }
308
276
  }
309
- /**
310
- * Resets the grid data while keeping columnDefs and sends a DATA_LOGOFF message if it's a stream.
311
- * @remarks This is used when the grid is already initialized and we want to reload the data due to a criteria/filter change.
312
- * @internal
313
- */
314
- reloadResourceData() {
315
- var _a, _b, _c;
316
- return __awaiter(this, void 0, void 0, function* () {
317
- this.ssrmDatasource.dataLogoff();
318
- this.clearRowData(withoutColumnDefs);
319
- this.ssrmDatasource = undefined;
320
- (_a = this.agGrid.gridApi) === null || _a === void 0 ? void 0 : _a.refreshServerSide({ purge: true });
321
- (_c = (_b = this.agGrid) === null || _b === void 0 ? void 0 : _b.gridApi) === null || _c === void 0 ? void 0 : _c.showLoadingOverlay();
322
- this.init();
323
- });
324
- }
325
277
  resourceNameChanged(oldValue, newValue) {
326
278
  if (!oldValue || oldValue === newValue)
327
279
  return;
@@ -342,7 +294,7 @@ let GridProServerSideDatasource = class GridProServerSideDatasource extends Life
342
294
  DOM.queueUpdate(() => {
343
295
  if (!shouldRunDisconnect)
344
296
  return;
345
- this.deinit();
297
+ this.reset();
346
298
  });
347
299
  }
348
300
  deepClone() {
@@ -351,13 +303,6 @@ let GridProServerSideDatasource = class GridProServerSideDatasource extends Life
351
303
  copy.deferredColumnStates = structuredClone(this.deferredColumnStates);
352
304
  return copy;
353
305
  }
354
- deinit() {
355
- var _a;
356
- this.clearRowData();
357
- this.ssrmDatasource = undefined;
358
- this.originalFieldDef = undefined;
359
- (_a = this.agGrid.gridApi) === null || _a === void 0 ? void 0 : _a.refreshServerSide({ purge: true });
360
- }
361
306
  init() {
362
307
  if (this.agGrid && this.resourceName && this.connect.isConnected) {
363
308
  this.agGrid.gridOptions = Object.assign({ getRowId: (params) => {
@@ -404,22 +349,25 @@ let GridProServerSideDatasource = class GridProServerSideDatasource extends Life
404
349
  }
405
350
  logger.warn(`Application not connected, falling back to local columnDefs/rowData`);
406
351
  }
352
+ reset() {
353
+ var _a;
354
+ this.clearRowData();
355
+ this.ssrmDatasource = undefined;
356
+ this.originalFieldDef = undefined;
357
+ (_a = this.agGrid.gridApi) === null || _a === void 0 ? void 0 : _a.refreshServerSide({ purge: true });
358
+ }
407
359
  restart() {
408
- this.deinit();
360
+ this.reset();
409
361
  this.init();
410
362
  }
411
- clearRowData(withColumnDefs = true) {
363
+ clearRowData() {
412
364
  var _a, _b, _c, _d;
413
- this.rowData = new Map();
414
- if (withColumnDefs) {
415
- (_b = (_a = this.agGrid) === null || _a === void 0 ? void 0 : _a.gridApi) === null || _b === void 0 ? void 0 : _b.setColumnDefs([]);
416
- }
417
- this.agTransaction = { remove: [] };
365
+ (_b = (_a = this.agGrid) === null || _a === void 0 ? void 0 : _a.gridApi) === null || _b === void 0 ? void 0 : _b.setColumnDefs([]);
366
+ const agTransaction = { remove: [] };
418
367
  (_c = this.agGrid.gridApi) === null || _c === void 0 ? void 0 : _c.forEachNode((node) => {
419
- this.agTransaction.remove.push(node.data);
368
+ agTransaction.remove.push(node.data);
420
369
  });
421
- (_d = this.agGrid.gridApi) === null || _d === void 0 ? void 0 : _d.applyServerSideTransaction(this.agTransaction);
422
- this.agTransaction = undefined;
370
+ (_d = this.agGrid.gridApi) === null || _d === void 0 ? void 0 : _d.applyServerSideTransaction(agTransaction);
423
371
  }
424
372
  getResourceIndexes(avaialbleIndexes) {
425
373
  const resourceIndexesMap = new Map();
@@ -2170,12 +2170,6 @@ export declare class GridProServerSideDatasource extends GridProServerSideDataso
2170
2170
  applyFuncName: string;
2171
2171
  applyAsyncFuncName: string;
2172
2172
  criteriaChanged(oldCriteria: string, newCriteria: string): void;
2173
- /**
2174
- * Resets the grid data while keeping columnDefs and sends a DATA_LOGOFF message if it's a stream.
2175
- * @remarks This is used when the grid is already initialized and we want to reload the data due to a criteria/filter change.
2176
- * @internal
2177
- */
2178
- private reloadResourceData;
2179
2173
  resourceNameChanged(oldValue: string, newValue: string): void;
2180
2174
  pagination: boolean;
2181
2175
  private indexes;
@@ -2184,8 +2178,8 @@ export declare class GridProServerSideDatasource extends GridProServerSideDataso
2184
2178
  connectedCallback(): void;
2185
2179
  disconnectedCallback(): void;
2186
2180
  deepClone(): Node;
2187
- deinit(): void;
2188
2181
  init(): void;
2182
+ reset(): void;
2189
2183
  restart(): void;
2190
2184
  private clearRowData;
2191
2185
  private getResourceIndexes;
@@ -2349,6 +2343,11 @@ declare const GridProServerSideDatasource_base: (new (...args: any[]) => {
2349
2343
  readonly DOCUMENT_TYPE_NODE: number;
2350
2344
  readonly ELEMENT_NODE: number;
2351
2345
  readonly ENTITY_NODE: number;
2346
+ /**
2347
+ * A Genesis Datasource element, for server-side | SSRM-compatible data fetching and used exclusively by the GridPro element.
2348
+ * @remarks Only supports Server-Side Row Model. Requires `@ag-grid-enterprise/server-side-row-model` setup and valid AG Grid Enterprise license.
2349
+ * @alpha
2350
+ */
2352
2351
  readonly ENTITY_REFERENCE_NODE: number;
2353
2352
  readonly NOTATION_NODE: number;
2354
2353
  readonly PROCESSING_INSTRUCTION_NODE: number;
@@ -2393,11 +2392,7 @@ declare const GridProServerSideDatasource_base: (new (...args: any[]) => {
2393
2392
  ariaValueMin: string;
2394
2393
  ariaValueNow: string;
2395
2394
  ariaValueText: string;
2396
- role: string; /**
2397
- * A Genesis Datasource element, for server-side | SSRM-compatible data fetching and used exclusively by the GridPro element.
2398
- * @remarks Only supports Server-Side Row Model. Requires `@ag-grid-enterprise/server-side-row-model` setup and valid AG Grid Enterprise license.
2399
- * @alpha
2400
- */
2395
+ role: string;
2401
2396
  animate(keyframes: PropertyIndexedKeyframes | Keyframe[], options?: number | KeyframeAnimationOptions): Animation;
2402
2397
  getAnimations(options?: GetAnimationsOptions): Animation[];
2403
2398
  after(...nodes: (string | Node)[]): void;
@@ -2711,11 +2706,9 @@ export declare class StreamDatasource extends StreamBaseDatasource implements IS
2711
2706
  constructor(options: StreamDatasourceOptions);
2712
2707
  getRows(params: IServerSideGetRowsParams): Promise<void>;
2713
2708
  private sortMapByNumericKey;
2714
- dataLogoff(): void;
2709
+ private dataLogoff;
2715
2710
  private restartSubscription;
2716
2711
  private getOrderByAndToBeSortedColIds;
2717
- private getAvailableIndexes;
2718
- private getAvailableIndexFields;
2719
2712
  private handleCurrentStreamLoad;
2720
2713
  private buildCriteriaMatchFromFilters;
2721
2714
  private criteriaFromFilters;
@@ -1015,8 +1015,6 @@ export class GridProServerSideDatasource extends GridProServerSideDatasource_bas
1015
1015
  // (undocumented)
1016
1016
  deepClone(): Node;
1017
1017
  // (undocumented)
1018
- deinit(): void;
1019
- // (undocumented)
1020
1018
  disconnectedCallback(): void;
1021
1019
  // (undocumented)
1022
1020
  init(): void;
@@ -1025,6 +1023,8 @@ export class GridProServerSideDatasource extends GridProServerSideDatasource_bas
1025
1023
  // (undocumented)
1026
1024
  get params(): any;
1027
1025
  // (undocumented)
1026
+ reset(): void;
1027
+ // (undocumented)
1028
1028
  resourceNameChanged(oldValue: string, newValue: string): void;
1029
1029
  // (undocumented)
1030
1030
  restart(): void;
@@ -1199,8 +1199,6 @@ export class StreamDatasource extends StreamBaseDatasource implements IServerSid
1199
1199
  // (undocumented)
1200
1200
  connect: Connect;
1201
1201
  // (undocumented)
1202
- dataLogoff(): void;
1203
- // (undocumented)
1204
1202
  dataserverStream: SocketObservable<FilteredDataServerResult>;
1205
1203
  // (undocumented)
1206
1204
  getRows(params: IServerSideGetRowsParams): Promise<void>;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@genesislcap/grid-pro",
3
3
  "description": "Genesis Foundation AG Grid",
4
- "version": "14.147.1-alpha-e9dbeac.0",
4
+ "version": "14.148.0",
5
5
  "sideEffects": false,
6
6
  "license": "SEE LICENSE IN license.txt",
7
7
  "main": "dist/esm/index.js",
@@ -30,20 +30,20 @@
30
30
  "test:debug": "genx test --debug"
31
31
  },
32
32
  "devDependencies": {
33
- "@genesislcap/foundation-testing": "14.147.1-alpha-e9dbeac.0",
34
- "@genesislcap/genx": "14.147.1-alpha-e9dbeac.0",
35
- "@genesislcap/rollup-builder": "14.147.1-alpha-e9dbeac.0",
36
- "@genesislcap/ts-builder": "14.147.1-alpha-e9dbeac.0",
37
- "@genesislcap/uvu-playwright-builder": "14.147.1-alpha-e9dbeac.0",
38
- "@genesislcap/vite-builder": "14.147.1-alpha-e9dbeac.0",
39
- "@genesislcap/webpack-builder": "14.147.1-alpha-e9dbeac.0",
33
+ "@genesislcap/foundation-testing": "14.148.0",
34
+ "@genesislcap/genx": "14.148.0",
35
+ "@genesislcap/rollup-builder": "14.148.0",
36
+ "@genesislcap/ts-builder": "14.148.0",
37
+ "@genesislcap/uvu-playwright-builder": "14.148.0",
38
+ "@genesislcap/vite-builder": "14.148.0",
39
+ "@genesislcap/webpack-builder": "14.148.0",
40
40
  "rimraf": "^3.0.2"
41
41
  },
42
42
  "dependencies": {
43
- "@genesislcap/foundation-comms": "14.147.1-alpha-e9dbeac.0",
44
- "@genesislcap/foundation-logger": "14.147.1-alpha-e9dbeac.0",
45
- "@genesislcap/foundation-ui": "14.147.1-alpha-e9dbeac.0",
46
- "@genesislcap/foundation-utils": "14.147.1-alpha-e9dbeac.0",
43
+ "@genesislcap/foundation-comms": "14.148.0",
44
+ "@genesislcap/foundation-logger": "14.148.0",
45
+ "@genesislcap/foundation-ui": "14.148.0",
46
+ "@genesislcap/foundation-utils": "14.148.0",
47
47
  "@microsoft/fast-colors": "^5.3.1",
48
48
  "@microsoft/fast-components": "^2.30.6",
49
49
  "@microsoft/fast-element": "^1.12.0",
@@ -68,5 +68,5 @@
68
68
  "access": "public"
69
69
  },
70
70
  "customElements": "dist/custom-elements.json",
71
- "gitHead": "409d501207d5051f3a556b0a6062feb84a84ae99"
71
+ "gitHead": "18e7851814a2c8025b486040224ff19b84fca29b"
72
72
  }