@datorama/core 21.4.0-rc.2 → 21.4.0-rc.3
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 -8
- package/bundles/datorama-core.umd.js.map +1 -1
- package/bundles/datorama-core.umd.min.js +1 -1
- package/bundles/datorama-core.umd.min.js.map +1 -1
- package/datorama-core.metadata.json +1 -1
- package/esm2015/lib/grid-v2/grid-store/grid.query.js +20 -9
- package/esm5/lib/grid-v2/grid-store/grid.query.js +20 -9
- package/fesm2015/datorama-core.js +18 -8
- package/fesm2015/datorama-core.js.map +1 -1
- package/fesm5/datorama-core.js +18 -8
- package/fesm5/datorama-core.js.map +1 -1
- package/package.json +1 -1
|
@@ -11565,14 +11565,24 @@
|
|
|
11565
11565
|
return settings;
|
|
11566
11566
|
};
|
|
11567
11567
|
GridQuery.prototype.getSort = function () {
|
|
11568
|
-
|
|
11569
|
-
|
|
11570
|
-
|
|
11571
|
-
|
|
11572
|
-
|
|
11573
|
-
|
|
11574
|
-
|
|
11575
|
-
|
|
11568
|
+
if (this.gridRef.gridOptions.pivotMode) {
|
|
11569
|
+
var _a = this.api.grid.getSortModel().pop() || {}, sort = _a.sort, colId_1 = _a.colId;
|
|
11570
|
+
var column = this.api.columns.getColumn(colId_1);
|
|
11571
|
+
var secondaryColumns = this.api.columns.getSecondaryColumns();
|
|
11572
|
+
var pivotedColumn_1 = secondaryColumns && secondaryColumns.find(function (col) { return col.getColId() === colId_1; });
|
|
11573
|
+
if (pivotedColumn_1) {
|
|
11574
|
+
var uniquePivotParents = uniq(secondaryColumns.map(function (column) { return column.getParent(); }));
|
|
11575
|
+
var secondaryColumn = secondaryColumns.find(function (col) { return col.getColId() === pivotedColumn_1.getColId(); });
|
|
11576
|
+
var pivotColIndex = uniquePivotParents.indexOf(secondaryColumn.getParent());
|
|
11577
|
+
return { colId: getColField(pivotedColumn_1.getColDef()), sort: sort, pivotColIndex: pivotColIndex };
|
|
11578
|
+
}
|
|
11579
|
+
else if (column) {
|
|
11580
|
+
return { colId: getColField(column.getColDef()), sort: sort };
|
|
11581
|
+
}
|
|
11582
|
+
}
|
|
11583
|
+
else {
|
|
11584
|
+
return this.api.grid.getSortModel().pop();
|
|
11585
|
+
}
|
|
11576
11586
|
};
|
|
11577
11587
|
GridQuery.prototype.selectSort = function () {
|
|
11578
11588
|
return this.select(function (state) { return state.settings.sort; });
|