@datorama/core 22.8.1-rc.3 → 22.8.2-rc.1
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.
- package/bundles/datorama-core.umd.js +18 -19
- package/bundles/datorama-core.umd.js.map +1 -1
- package/bundles/datorama-core.umd.min.js +3 -3
- package/bundles/datorama-core.umd.min.js.map +1 -1
- package/datorama-core.metadata.json +1 -1
- package/esm2015/lib/grid-v2/grid/grid-v2.types.js +1 -1
- package/esm2015/lib/grid-v2/grid-controller/grid-controller.component.js +3 -1
- package/esm2015/lib/grid-v2/grid-store/grid.query.js +12 -14
- package/esm2015/lib/grid-v2/grid-store/grid.service.js +6 -6
- package/esm2015/lib/version.js +2 -2
- package/esm5/lib/grid-v2/grid/grid-v2.types.js +1 -1
- package/esm5/lib/grid-v2/grid-controller/grid-controller.component.js +3 -1
- package/esm5/lib/grid-v2/grid-store/grid.query.js +12 -14
- package/esm5/lib/grid-v2/grid-store/grid.service.js +6 -6
- package/esm5/lib/version.js +2 -2
- package/fesm2015/datorama-core.js +18 -19
- package/fesm2015/datorama-core.js.map +1 -1
- package/fesm5/datorama-core.js +18 -19
- package/fesm5/datorama-core.js.map +1 -1
- package/lib/grid-v2/grid/grid-v2.types.d.ts +1 -0
- package/lib/grid-v2/grid-store/grid.query.d.ts +1 -1
- package/package.json +1 -1
|
@@ -11581,7 +11581,7 @@
|
|
|
11581
11581
|
var storeSettings = this.getValue().settings;
|
|
11582
11582
|
var settings = {
|
|
11583
11583
|
gridAlignment: storeSettings.gridAlignment,
|
|
11584
|
-
sort: this.getSort(),
|
|
11584
|
+
sort: this.getGridOptions().sortByStore ? this.getSort() : this.getSortModel(),
|
|
11585
11585
|
hiddenColumns: hiddenColumns,
|
|
11586
11586
|
groupedColumns: groupedColumns.map(toColId),
|
|
11587
11587
|
filter: this.getFilter(),
|
|
@@ -11595,31 +11595,29 @@
|
|
|
11595
11595
|
}
|
|
11596
11596
|
return settings;
|
|
11597
11597
|
};
|
|
11598
|
-
GridQuery.prototype.
|
|
11598
|
+
GridQuery.prototype.getSortModel = function () {
|
|
11599
11599
|
return this.api.grid.getSortModel().pop();
|
|
11600
11600
|
};
|
|
11601
|
+
GridQuery.prototype.getSort = function () {
|
|
11602
|
+
return this.getValue().settings.sort || this.getSortModel();
|
|
11603
|
+
};
|
|
11601
11604
|
GridQuery.prototype.getExternalSort = function () {
|
|
11602
|
-
var _a = this.getSort() || {}, sort = _a.sort, colId = _a.colId;
|
|
11605
|
+
var _a = this.getSort() || {}, sort = _a.sort, colId = _a.colId, savedSortIndex = _a.sortIndex;
|
|
11603
11606
|
var column = this.api.columns.getColumn(colId);
|
|
11604
11607
|
var allColumns = this.api.columns.getAllGridColumns();
|
|
11605
11608
|
if (column) {
|
|
11606
|
-
|
|
11609
|
+
var field = getColField(column.getColDef());
|
|
11610
|
+
return { colId: colId, sort: sort, field: field };
|
|
11607
11611
|
}
|
|
11608
11612
|
else {
|
|
11609
11613
|
var secondaryColumn = this.getSecondaryColumn(colId);
|
|
11610
11614
|
if (secondaryColumn) {
|
|
11611
|
-
|
|
11612
|
-
|
|
11613
|
-
|
|
11614
|
-
field: getColField(secondaryColumn.getColDef()),
|
|
11615
|
-
sortIndex: allColumns.indexOf(secondaryColumn)
|
|
11616
|
-
};
|
|
11615
|
+
var sortIndex = savedSortIndex || allColumns.indexOf(secondaryColumn);
|
|
11616
|
+
var field = getColField(secondaryColumn.getColDef());
|
|
11617
|
+
return { colId: colId, sort: sort, field: field, sortIndex: sortIndex };
|
|
11617
11618
|
}
|
|
11618
11619
|
}
|
|
11619
11620
|
};
|
|
11620
|
-
GridQuery.prototype.selectSort = function () {
|
|
11621
|
-
return this.select(function (state) { return state.settings.sort; });
|
|
11622
|
-
};
|
|
11623
11621
|
/* @internal */
|
|
11624
11622
|
GridQuery.prototype._setApi = function (api, gridRef) {
|
|
11625
11623
|
this.api = api;
|
|
@@ -14472,11 +14470,11 @@
|
|
|
14472
14470
|
if (isPivotColId || valueColumn) {
|
|
14473
14471
|
/** Column is pivot value column, sort by index */
|
|
14474
14472
|
var columnByIndex = gridColumns[sortIndex];
|
|
14475
|
-
|
|
14476
|
-
|
|
14477
|
-
if (pivotValueColumnId ===
|
|
14478
|
-
|
|
14479
|
-
}
|
|
14473
|
+
// const pivotValueColumn = columnByIndex && columnByIndex.getColDef().pivotValueColumn;
|
|
14474
|
+
// const pivotValueColumnId = pivotValueColumn && pivotValueColumn.getColId();
|
|
14475
|
+
// if (pivotValueColumnId === colId) {
|
|
14476
|
+
sortToApply = { colId: columnByIndex.getColId(), sort: sort, sortIndex: sortIndex };
|
|
14477
|
+
// }
|
|
14480
14478
|
}
|
|
14481
14479
|
else {
|
|
14482
14480
|
/** Sort by column id */
|
|
@@ -15675,6 +15673,7 @@
|
|
|
15675
15673
|
type: type,
|
|
15676
15674
|
data: data
|
|
15677
15675
|
});
|
|
15676
|
+
triggerWindowResize();
|
|
15678
15677
|
});
|
|
15679
15678
|
};
|
|
15680
15679
|
DatoGridControllerComponent.prototype.listenToStoreSettingsChanges = function () {
|
|
@@ -25467,7 +25466,7 @@
|
|
|
25467
25466
|
};
|
|
25468
25467
|
}
|
|
25469
25468
|
|
|
25470
|
-
window.coreVersion = '22.8.
|
|
25469
|
+
window.coreVersion = '22.8.2-rc.';
|
|
25471
25470
|
|
|
25472
25471
|
exports.APP_TRANSLATE = APP_TRANSLATE;
|
|
25473
25472
|
exports.AceService = AceService;
|