@fluxhub/fluxhub-lib 19.0.150 → 19.0.151
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.
|
@@ -9426,6 +9426,39 @@ class FHGridComponent {
|
|
|
9426
9426
|
b_restored = false;
|
|
9427
9427
|
str_curr_q_p = '';
|
|
9428
9428
|
p_fi = {};
|
|
9429
|
+
/**
|
|
9430
|
+
* Converts numeric filter values to strings for backend compatibility
|
|
9431
|
+
* AG Grid sends numbers for numeric filters, but .NET backend expects strings
|
|
9432
|
+
*/
|
|
9433
|
+
normalizeFilterModel(filterModel) {
|
|
9434
|
+
if (!filterModel)
|
|
9435
|
+
return filterModel;
|
|
9436
|
+
const normalized = {};
|
|
9437
|
+
for (const key in filterModel) {
|
|
9438
|
+
if (filterModel.hasOwnProperty(key)) {
|
|
9439
|
+
const filter = { ...filterModel[key] };
|
|
9440
|
+
// Convert main filter value if it's a number
|
|
9441
|
+
if (filter.filter != null && typeof filter.filter === 'number') {
|
|
9442
|
+
filter.filter = filter.filter.toString();
|
|
9443
|
+
}
|
|
9444
|
+
// Handle combined filters (AND/OR conditions)
|
|
9445
|
+
if (filter.condition1) {
|
|
9446
|
+
filter.condition1 = { ...filter.condition1 };
|
|
9447
|
+
if (filter.condition1.filter != null && typeof filter.condition1.filter === 'number') {
|
|
9448
|
+
filter.condition1.filter = filter.condition1.filter.toString();
|
|
9449
|
+
}
|
|
9450
|
+
}
|
|
9451
|
+
if (filter.condition2) {
|
|
9452
|
+
filter.condition2 = { ...filter.condition2 };
|
|
9453
|
+
if (filter.condition2.filter != null && typeof filter.condition2.filter === 'number') {
|
|
9454
|
+
filter.condition2.filter = filter.condition2.filter.toString();
|
|
9455
|
+
}
|
|
9456
|
+
}
|
|
9457
|
+
normalized[key] = filter;
|
|
9458
|
+
}
|
|
9459
|
+
}
|
|
9460
|
+
return normalized;
|
|
9461
|
+
}
|
|
9429
9462
|
dataSource = {
|
|
9430
9463
|
getRows: (params) => {
|
|
9431
9464
|
this.num_r = -1;
|
|
@@ -9442,7 +9475,7 @@ class FHGridComponent {
|
|
|
9442
9475
|
p.exec_params = this.exec_params || [];
|
|
9443
9476
|
p.p = JSON.stringify({
|
|
9444
9477
|
sort_model: params.request.sortModel,
|
|
9445
|
-
filter_model: params.request.filterModel,
|
|
9478
|
+
filter_model: this.normalizeFilterModel(params.request.filterModel),
|
|
9446
9479
|
free_search: this.ric_libera,
|
|
9447
9480
|
fix_flt: this.fix_flt || '',
|
|
9448
9481
|
});
|