@refinitiv-ui/efx-grid 6.0.97 → 6.0.98
Sign up to get free protection for your applications and to get access to all the features.
@@ -236,7 +236,9 @@ declare class DataView extends EventDispatcher {
|
|
236
236
|
|
237
237
|
public searchNext(rowRef: number|string|null, searchLogic: ((...params: any[]) => any)|null): number;
|
238
238
|
|
239
|
-
public stall(
|
239
|
+
public stall(bool?: boolean|null): boolean;
|
240
|
+
|
241
|
+
public stallSorting(bool?: boolean|null): boolean;
|
240
242
|
|
241
243
|
public enableAutoGroupRemoval(opt_bool?: boolean|null): boolean;
|
242
244
|
|
@@ -302,6 +302,10 @@ DataView.prototype._wrapSize = 0;
|
|
302
302
|
* @type {number}
|
303
303
|
*/
|
304
304
|
DataView.prototype._wrapTimerId = 0;
|
305
|
+
/** @private
|
306
|
+
* @type {boolean}
|
307
|
+
*/
|
308
|
+
DataView.prototype._stalledSorting = false;
|
305
309
|
|
306
310
|
/** @public
|
307
311
|
* @fires DataView#preDisposed
|
@@ -2344,11 +2348,11 @@ DataView.prototype._searchRow = function(rids, searchLogic, start, end, inc) {
|
|
2344
2348
|
|
2345
2349
|
/** Blocks all row insertion and removal, but keep updating the data
|
2346
2350
|
* @public
|
2347
|
-
* @param {boolean=}
|
2348
|
-
* @return {boolean}
|
2351
|
+
* @param {boolean=} bool
|
2352
|
+
* @return {boolean} Returns true, if there is any change
|
2349
2353
|
*/
|
2350
|
-
DataView.prototype.stall = function(
|
2351
|
-
let newBool =
|
2354
|
+
DataView.prototype.stall = function(bool) {
|
2355
|
+
let newBool = bool !== false;
|
2352
2356
|
let curBool = this._shared.stalledRids ? true : false;
|
2353
2357
|
if(curBool === newBool) { return false; }
|
2354
2358
|
if(newBool) {
|
@@ -2365,6 +2369,25 @@ DataView.prototype.stall = function(opt_bool) {
|
|
2365
2369
|
}
|
2366
2370
|
return true;
|
2367
2371
|
};
|
2372
|
+
/** Blocks existing sorting from performing on every data change
|
2373
|
+
* @public
|
2374
|
+
* @param {boolean=} bool
|
2375
|
+
* @return {boolean} Returns true, if there is any change
|
2376
|
+
*/
|
2377
|
+
DataView.prototype.stallSorting = function(bool) {
|
2378
|
+
let newBool = bool !== false;
|
2379
|
+
if(this._stalledSorting !== newBool) {
|
2380
|
+
this._stalledSorting = newBool;
|
2381
|
+
|
2382
|
+
if(!newBool && this.isSorting()) {
|
2383
|
+
if(this._sort()) {
|
2384
|
+
this._dispatchDataChange(DataTable._positionChangeArg);
|
2385
|
+
}
|
2386
|
+
}
|
2387
|
+
}
|
2388
|
+
return true;
|
2389
|
+
};
|
2390
|
+
|
2368
2391
|
/** Automatically and asyncronuosly remove group that has no member or no content. Predefined groups will not be removed in this way.
|
2369
2392
|
* @public
|
2370
2393
|
* @param {boolean=} opt_bool
|
@@ -2400,7 +2423,7 @@ DataView.prototype.enableAutoGroupHiding = function(opt_bool) {
|
|
2400
2423
|
* @public
|
2401
2424
|
*/
|
2402
2425
|
DataView.prototype.synchronizeRowOrder = function() {
|
2403
|
-
if(this.isSorting()) {
|
2426
|
+
if(!this._stalledSorting && this.isSorting()) {
|
2404
2427
|
this._dt._sort(this._sortingDefs);
|
2405
2428
|
}
|
2406
2429
|
};
|
@@ -3453,6 +3476,9 @@ DataView.prototype._sort = function() {
|
|
3453
3476
|
if(this._groupMembers) {
|
3454
3477
|
return false; // DataView with children should not be sorted as sort operation will be done on each child
|
3455
3478
|
}
|
3479
|
+
if(this._stalledSorting) {
|
3480
|
+
return false;
|
3481
|
+
}
|
3456
3482
|
|
3457
3483
|
if(this._dt._getSegmentSeparators() || this.isSorting()) {
|
3458
3484
|
let rids = this._rids;
|
package/lib/grid/index.js
CHANGED
package/package.json
CHANGED