diff options
| author | bobzel <zzzman@gmail.com> | 2020-10-05 16:00:34 -0400 |
|---|---|---|
| committer | bobzel <zzzman@gmail.com> | 2020-10-05 16:00:34 -0400 |
| commit | 9c4701f8a8214544a0e1e6b31887d393e8ad344f (patch) | |
| tree | d4d845ba16cac968f23f8b6ece782651980f9478 | |
| parent | 56d9d31d4ac9f2913bec14a2e3c4472fcfd90a7b (diff) | |
fixed search over DB to not use quotes when setting field column filters.
| -rw-r--r-- | src/client/views/search/SearchBox.tsx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/views/search/SearchBox.tsx b/src/client/views/search/SearchBox.tsx index b381bbfa9..1104d8d2a 100644 --- a/src/client/views/search/SearchBox.tsx +++ b/src/client/views/search/SearchBox.tsx @@ -146,7 +146,7 @@ export class SearchBox extends ViewBoxBaseComponent<FieldViewProps, SearchBoxDoc const mod = "_t:"; const newWords: string[] = []; const oldWords = values[0].split(" "); - oldWords.forEach((word, i) => i === 0 ? newWords.push(key + mod + "\"" + word + "\"") : newWords.push("AND " + key + mod + "\"" + word + "\"")); + oldWords.forEach((word, i) => i === 0 ? newWords.push(key + mod + word) : newWords.push("AND " + key + mod + word)); query = `(${query}) AND (${newWords.join(" ")})`; } else { @@ -154,7 +154,7 @@ export class SearchBox extends ViewBoxBaseComponent<FieldViewProps, SearchBoxDoc const mod = "_t:"; const newWords: string[] = []; const oldWords = values[i].split(" "); - oldWords.forEach((word, i) => i === 0 ? newWords.push(key + mod + "\"" + word + "\"") : newWords.push("AND " + key + mod + "\"" + word + "\"")); + oldWords.forEach((word, i) => i === 0 ? newWords.push(key + mod + word) : newWords.push("AND " + key + mod + word)); const v = "(" + newWords.join(" ") + ")"; if (i === 0) { query = `(${query}) AND (${v}` + (values.length === 1 ? ")" : ""); |
