1
0
Fork 0
mirror of synced 2024-07-03 05:20:32 +12:00

Fix lucene not allowed characters

This commit is contained in:
Peter Clement 2021-08-26 11:39:42 +01:00
parent 4cfcae415e
commit f7ebf7f8a4
3 changed files with 3 additions and 7 deletions

View file

@ -34,11 +34,7 @@
{:else if type === "boolean"}
<Toggle text={label} bind:value data-cy="{meta.name}-input" />
{:else if type === "array"}
<Multiselect
bind:value
{label}
options={meta.constraints.inclusion.reduce((p, n) => p.concat(n), [])}
/>
<Multiselect bind:value {label} options={meta.constraints.inclusion.flat()} />
{:else if type === "link"}
<LinkedRowSelector bind:linkedRows={value} schema={meta} />
{:else if type === "longform"}

View file

@ -62,7 +62,7 @@
}
// if changed to an array, change default value to empty array
const idx = filters.findIndex(x => (x.field = field))
const idx = filters.findIndex(x => x.field === field)
if (expression.type === "array") {
filters[idx].value = []
} else {

View file

@ -133,7 +133,7 @@ class QueryBuilder {
}
// Escape characters
if (escape && originalType === "string") {
value = `${value}`.replace(/[ #+\-&|!{}\]^"~*?:\\]/g, "\\$&")
value = `${value}`.replace(/[ #+\-&|!(){}\]^"~*?:\\]/g, "\\$&")
}
// Wrap in quotes
if (hasVersion && wrap) {