mirror of
https://github.com/dbgate/dbgate
synced 2024-11-07 20:26:23 +00:00
jsonl filtering fixes
This commit is contained in:
parent
cf3df9cda3
commit
dbfdaafb86
@ -6,7 +6,7 @@ import { dumpSqlSourceRef } from './dumpSqlSource';
|
||||
export function evaluateExpression(expr: Expression, values) {
|
||||
switch (expr.exprType) {
|
||||
case 'column':
|
||||
return values[expr.columnName];
|
||||
return _.get(values, expr.columnName);
|
||||
|
||||
case 'placeholder':
|
||||
return values.__placeholder;
|
||||
|
@ -33,6 +33,7 @@
|
||||
export let customCommandIcon = null;
|
||||
export let onCustomCommand = null;
|
||||
export let customCommandTooltip = null;
|
||||
export let formatterFunction = null;
|
||||
|
||||
export let pureName = null;
|
||||
export let schemaName = null;
|
||||
@ -276,6 +277,7 @@
|
||||
schemaName,
|
||||
pureName,
|
||||
field: columnName || uniqueName,
|
||||
formatterFunction,
|
||||
onConfirm: keys => setFilter(keys.map(x => getFilterValueExpression(x)).join(',')),
|
||||
});
|
||||
}
|
||||
|
@ -355,6 +355,7 @@
|
||||
export let pureName = undefined;
|
||||
export let schemaName = undefined;
|
||||
export let allowDefineVirtualReferences = false;
|
||||
export let formatterFunction;
|
||||
|
||||
export let isLoadedAll;
|
||||
export let loadedTime;
|
||||
@ -1743,6 +1744,7 @@
|
||||
{conid}
|
||||
{database}
|
||||
{jslid}
|
||||
{formatterFunction}
|
||||
driver={display?.driver}
|
||||
filterType={useEvalFilters ? 'eval' : col.filterType || getFilterType(col.dataType)}
|
||||
filter={display.getFilter(col.uniqueName)}
|
||||
|
@ -25,6 +25,7 @@
|
||||
export let driver;
|
||||
export let multiselect = false;
|
||||
export let jslid;
|
||||
export let formatterFunction;
|
||||
|
||||
// console.log('ValueLookupModal', conid, database, pureName, schemaName, columnName, driver);
|
||||
|
||||
@ -42,6 +43,7 @@
|
||||
jslid,
|
||||
search,
|
||||
field,
|
||||
formatterFunction,
|
||||
});
|
||||
} else {
|
||||
rows = await apiCall('database-connections/load-field-values', {
|
||||
|
Loading…
Reference in New Issue
Block a user