@syncfusion/ej2-treegrid 26.1.41 → 26.1.42
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/dist/ej2-treegrid.min.js +2 -2
- package/dist/ej2-treegrid.umd.min.js +2 -2
- package/dist/ej2-treegrid.umd.min.js.map +1 -1
- package/dist/es6/ej2-treegrid.es2015.js +21 -3
- package/dist/es6/ej2-treegrid.es2015.js.map +1 -1
- package/dist/es6/ej2-treegrid.es5.js +21 -3
- package/dist/es6/ej2-treegrid.es5.js.map +1 -1
- package/dist/global/ej2-treegrid.min.js +2 -2
- package/dist/global/ej2-treegrid.min.js.map +1 -1
- package/dist/global/index.d.ts +1 -1
- package/package.json +9 -9
- package/src/treegrid/base/data.d.ts +1 -0
- package/src/treegrid/base/data.js +13 -1
- package/src/treegrid/base/treegrid.js +1 -1
- package/src/treegrid/renderer/virtual-row-model-generator.js +7 -1
|
@@ -2047,6 +2047,7 @@ var DataManipulation = /** @__PURE__ @class */ (function () {
|
|
|
2047
2047
|
this.hierarchyData = [];
|
|
2048
2048
|
this.storedIndex = -1;
|
|
2049
2049
|
this.sortedData = [];
|
|
2050
|
+
this.preCurrentPage = -1;
|
|
2050
2051
|
this.isSortAction = false;
|
|
2051
2052
|
this.addEventListener();
|
|
2052
2053
|
this.dataResults = {};
|
|
@@ -2378,7 +2379,7 @@ var DataManipulation = /** @__PURE__ @class */ (function () {
|
|
|
2378
2379
|
idMappingValue = rowDetails.record[this.parent.idMapping].toString();
|
|
2379
2380
|
}
|
|
2380
2381
|
if (this.parent.enableVirtualization && rowDetails.action === 'remoteExpand') {
|
|
2381
|
-
qry.take(this.parent.pageSettings.pageSize);
|
|
2382
|
+
qry.take(this.parent.grid.pageSettings.pageSize);
|
|
2382
2383
|
var expandDetail = [];
|
|
2383
2384
|
expandDetail.push('ExpandingAction', idMappingValue.toString());
|
|
2384
2385
|
qry.expand(expandDetail);
|
|
@@ -2566,6 +2567,17 @@ var DataManipulation = /** @__PURE__ @class */ (function () {
|
|
|
2566
2567
|
}
|
|
2567
2568
|
datas.splice(inx + r + 1, 0, result[parseInt(r.toString(), 10)]);
|
|
2568
2569
|
}
|
|
2570
|
+
if (datas.length > result.length &&
|
|
2571
|
+
datas.length !== _this.parent.grid.pageSettings.pageSize + (_this.parent.grid.contentModule).getBlockSize() &&
|
|
2572
|
+
_this.parent.enableVirtualization && rowDetails.action === 'remoteExpand') {
|
|
2573
|
+
if ((_this.preCurrentPage > 1 || _this.parent.grid.pageSettings.currentPage > 1)) {
|
|
2574
|
+
datas = datas.slice(0, _this.parent.grid.pageSettings.pageSize + (_this.parent.grid.contentModule).getBlockSize());
|
|
2575
|
+
}
|
|
2576
|
+
else {
|
|
2577
|
+
datas = datas.slice(0, _this.parent.grid.pageSettings.pageSize);
|
|
2578
|
+
}
|
|
2579
|
+
_this.preCurrentPage = _this.parent.grid.pageSettings.currentPage;
|
|
2580
|
+
}
|
|
2569
2581
|
setValue('result', datas, e);
|
|
2570
2582
|
setValue('action', 'beforecontentrender', e);
|
|
2571
2583
|
_this.parent.trigger(actionComplete, e);
|
|
@@ -4526,7 +4538,7 @@ var TreeGrid = /** @__PURE__ @class */ (function (_super) {
|
|
|
4526
4538
|
|| (/[0-9]$/.test(this.height.toString()) && /[px]$/.test(this.height.toString()))) {
|
|
4527
4539
|
failureCases.push('column width and height should be in pixels');
|
|
4528
4540
|
}
|
|
4529
|
-
if (
|
|
4541
|
+
if ((this.childMapping !== 'Children') && !isNullOrUndefined(this.idMapping)) {
|
|
4530
4542
|
failureCases.push('Both IdMapping and ChildMapping should not be used together for tree grid rendering.');
|
|
4531
4543
|
}
|
|
4532
4544
|
if ((!isNullOrUndefined(this.idMapping) && (isNullOrUndefined(this.parentIdMapping))) ||
|
|
@@ -9914,7 +9926,13 @@ var TreeVirtualRowModelGenerator = /** @__PURE__ @class */ (function (_super) {
|
|
|
9914
9926
|
else if (action === 'virtualscroll' && this.cache[parseInt(currentPage.toString(), 10)] &&
|
|
9915
9927
|
this.cache[parseInt(currentPage.toString(), 10)].length >
|
|
9916
9928
|
(this.parent.contentModule).getBlockSize()) {
|
|
9917
|
-
|
|
9929
|
+
if (this.cache[parseInt(currentPage.toString(), 10)].length > (this.parent.contentModule).getBlockSize()) {
|
|
9930
|
+
this.cache[parseInt(currentPage.toString(), 10)] =
|
|
9931
|
+
this.cache[parseInt(currentPage.toString(), 10)].slice(0, (this.parent.contentModule).getBlockSize());
|
|
9932
|
+
}
|
|
9933
|
+
else {
|
|
9934
|
+
delete this.cache[parseInt(currentPage.toString(), 10)];
|
|
9935
|
+
}
|
|
9918
9936
|
}
|
|
9919
9937
|
}
|
|
9920
9938
|
else {
|