mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-01-02 05:33:17 +08:00
Merge pull request #7622 from rekonder/aj_SCI_10753
Espace special character for search [SCI-10753]
This commit is contained in:
commit
85c1362903
1 changed files with 1 additions and 1 deletions
|
@ -203,7 +203,7 @@ module SearchableModel
|
|||
|
||||
new_phrase = exact_match ? phrase[1..-2] : phrase
|
||||
if DATA_VECTOR_ATTRIBUTES.include?(attribute)
|
||||
new_phrase = Regexp.escape(new_phrase.gsub(/[!()&|:]/, ' ').strip).split(/\s+/)
|
||||
new_phrase = Regexp.escape(new_phrase.gsub(/[!()&|:<]/, ' ').strip).split(/\s+/)
|
||||
new_phrase.map! { |t| "#{t}:*" } unless exact_match
|
||||
new_phrase = new_phrase.join('&').tr('\'', '"')
|
||||
else
|
||||
|
|
Loading…
Reference in a new issue