Support for string bindings as array

This commit is contained in:
Mel O'Hagan 2022-07-27 17:34:42 +01:00
parent 26c8af3c1e
commit 1afb64d7f9
1 changed files with 3 additions and 0 deletions

View File

@ -121,6 +121,9 @@ export const buildLuceneQuery = filter => {
if (type === "boolean") { if (type === "boolean") {
value = `${value}`?.toLowerCase() === "true" value = `${value}`?.toLowerCase() === "true"
} }
if (["contains", "notContains", "containsAny"].includes(operator) && type === "array" && typeof value === "string") {
value = value.split(",")
}
if (operator.startsWith("range")) { if (operator.startsWith("range")) {
const minint = const minint =
SqlNumberTypeRangeMap[externalType]?.min || Number.MIN_SAFE_INTEGER SqlNumberTypeRangeMap[externalType]?.min || Number.MIN_SAFE_INTEGER