basesite-shared-grid-lib 21.0.1-beta.6 → 21.0.1-beta.7

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.
@@ -239,7 +239,7 @@ class OdataProvider {
239
239
  query = query + '&' + customFilters.join('and');
240
240
  }
241
241
  }
242
- query = query.replace('and$filter=', '&filter=');
242
+ query = query.replace('and$filter=', '&$filter=');
243
243
  return query;
244
244
  };
245
245
  /**
@@ -2746,8 +2746,17 @@ class GridLibraryComponent {
2746
2746
  // Add timeout to prevent infinite loading
2747
2747
  const API_TIMEOUT = 800000; //80 seconds
2748
2748
  let hasRetried = false;
2749
+ // Fill-cell columns use the set filter, which only emits exact-match
2750
+ // predicates (eq / in). Wrapping those in tolower() forces the DB to
2751
+ // scan + lowercase every row (non-sargable), which was making filter
2752
+ // requests ~10x+ slower than baseline. Skip tolower() for these
2753
+ // columns by registering them as caseSensitive with the provider.
2754
+ const fillCellFields = (this.initialColumnDef ?? [])
2755
+ .filter((c) => c?.columnType === 'fill' && c?.field)
2756
+ .map((c) => c.field);
2749
2757
  this.odataProvider = new OdataServerSideProvider({
2750
2758
  isCaseSensitiveStringFilter: false,
2759
+ caseSensitiveColumns: fillCellFields,
2751
2760
  callApi: (options) => {
2752
2761
  const url = this.setExternalFilters(options);
2753
2762
  console.log('Server-side API call:', url);