@fto-consult/expo-ui 6.73.8 → 6.73.10

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fto-consult/expo-ui",
3
- "version": "6.73.8",
3
+ "version": "6.73.10",
4
4
  "description": "Bibliothèque de composants UI Expo,react-native",
5
5
  "main": "main",
6
6
  "scripts": {
@@ -7,7 +7,7 @@ import {defaultStr,extendObj,isFunction,defaultVal,isObjOrArray,defaultObj} from
7
7
  import PropTypes from "prop-types";
8
8
  import actions from "$cactions";
9
9
  import {navigateToTableData} from "$enavigation/utils";
10
- import {getFetchOptions,prepareFilters} from "$cutils/filters";
10
+ import {getFetchOptions,prepareFilters,convertToSQL as convFiltersToSQL} from "$cutils/filters";
11
11
  import fetch from "$capi"
12
12
  import React from "$react";
13
13
  import useApp from "$econtext/hooks";
@@ -147,11 +147,12 @@ const TableDataSelectField = React.forwardRef(({foreignKeyColumn,foreignKeyLabel
147
147
  if(!isMounted()) return;
148
148
  if(typeof beforeFetchItems ==='function' && beforeFetchItems({fetchOptions}) === false) return;
149
149
  let opts = Object.clone(fetchOptions);
150
- if(cPrepareFilters !== false){
151
- opts.selector = prepareFilters(fetchOptions.selector,{convertToSQL:convertFiltersToSQL});
150
+ if(convertFiltersToSQL){
151
+ opts.selector = convFiltersToSQL(opts.selector);
152
152
  opts = getFetchOptions(opts);
153
+ delete opts.selector;
153
154
  } else {
154
- opts = {fetchOptions};
155
+ opts = {fetchOptions:opts};
155
156
  }
156
157
  const r = fetchItems(opts);
157
158
  if(r === false) return;