@churchillliving/se-ui-toolkit 6.53.338 → 6.53.339
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/churchillliving-se-ui-toolkit.umd.js +31 -32
- package/bundles/churchillliving-se-ui-toolkit.umd.js.map +1 -1
- package/esm2015/lib/components/base/grid/grid.component.js +30 -31
- package/fesm2015/churchillliving-se-ui-toolkit.js +31 -32
- package/fesm2015/churchillliving-se-ui-toolkit.js.map +1 -1
- package/package.json +1 -1
|
@@ -3899,7 +3899,7 @@
|
|
|
3899
3899
|
// Global filter server request
|
|
3900
3900
|
set: function (globalFilters) {
|
|
3901
3901
|
var _this = this;
|
|
3902
|
-
var _a, _b;
|
|
3902
|
+
var _a, _b, _c;
|
|
3903
3903
|
this.globalData = (_a = this.gridService
|
|
3904
3904
|
.prepareGlobalFilters(globalFilters)) === null || _a === void 0 ? void 0 : _a.filter(function (x) { return (x === null || x === void 0 ? void 0 : x.value) !== false; });
|
|
3905
3905
|
var serverFilterValues = JSON.parse(JSON.stringify(this.serverFilters));
|
|
@@ -3926,37 +3926,36 @@
|
|
|
3926
3926
|
});
|
|
3927
3927
|
});
|
|
3928
3928
|
this.loading = this.autoLoadData;
|
|
3929
|
-
setTimeout(
|
|
3930
|
-
|
|
3931
|
-
|
|
3932
|
-
|
|
3933
|
-
|
|
3934
|
-
|
|
3935
|
-
|
|
3936
|
-
|
|
3937
|
-
|
|
3938
|
-
|
|
3939
|
-
|
|
3940
|
-
|
|
3941
|
-
|
|
3942
|
-
|
|
3943
|
-
|
|
3944
|
-
|
|
3945
|
-
|
|
3946
|
-
|
|
3947
|
-
|
|
3948
|
-
|
|
3949
|
-
|
|
3950
|
-
|
|
3951
|
-
|
|
3952
|
-
|
|
3953
|
-
|
|
3954
|
-
|
|
3955
|
-
|
|
3956
|
-
|
|
3957
|
-
|
|
3958
|
-
|
|
3959
|
-
}, 300);
|
|
3929
|
+
// setTimeout(() => {
|
|
3930
|
+
if (this.gridService.applyFilterEvent || this.autoLoadData) {
|
|
3931
|
+
this.onApplyFilter.emit();
|
|
3932
|
+
}
|
|
3933
|
+
if (this.globalFiltersArray && this.globalFiltersArray.length > 0) {
|
|
3934
|
+
serverFilterValues.filters = serverFilterValues.filters.concat(this.globalFiltersArray);
|
|
3935
|
+
}
|
|
3936
|
+
serverFilterValues.filters = Array.from(new Set(serverFilterValues.filters
|
|
3937
|
+
.reverse()
|
|
3938
|
+
.map(function (filter) { return filter.field; }))).map(function (field) {
|
|
3939
|
+
return serverFilterValues.filters.find(function (x) { return x.field === field; });
|
|
3940
|
+
});
|
|
3941
|
+
serverFilterValues.filters = serverFilterValues.filters.filter(function (obj) { var _a, _b; return (obj === null || obj === void 0 ? void 0 : obj.value) && ((_b = (_a = obj.value) === null || _a === void 0 ? void 0 : _a.toString()) === null || _b === void 0 ? void 0 : _b.length) > 0 && obj.field; });
|
|
3942
|
+
this.gridService.softCachingFilters[((_c = this.componentTableRef) === null || _c === void 0 ? void 0 : _c.id) + currentUrl()] = serverFilterValues;
|
|
3943
|
+
if (this.gridService.applyFilterEvent || this.autoLoadData === true) {
|
|
3944
|
+
// setting pagination page as first
|
|
3945
|
+
serverFilterValues.page = 1;
|
|
3946
|
+
this.autoLoadData = true;
|
|
3947
|
+
if (this.defaultRows && this.pagination) {
|
|
3948
|
+
serverFilterValues.pageSize = this.defaultRows;
|
|
3949
|
+
}
|
|
3950
|
+
if (this.gridService.applyFilterEvent) {
|
|
3951
|
+
this.isCheckBoxChangeEventCalled = false;
|
|
3952
|
+
this.onServerSideEventChange.emit(serverFilterValues);
|
|
3953
|
+
}
|
|
3954
|
+
localStorage.removeItem('applyFilter');
|
|
3955
|
+
// setting pagination page number UI
|
|
3956
|
+
this.table._first = 0;
|
|
3957
|
+
}
|
|
3958
|
+
// }, 300);
|
|
3960
3959
|
}
|
|
3961
3960
|
},
|
|
3962
3961
|
enumerable: false,
|