diff --git a/application/database/db.py b/application/database/db.py index 6c1613277..6b0190dfb 100644 --- a/application/database/db.py +++ b/application/database/db.py @@ -1806,7 +1806,7 @@ def text_search(self, text: str) -> List[Optional[cre_defs.Document]]: 'CRE:' will search for the in cre names ':[:
::]' will search for all entries of and optionally, section/subsection - '\d\d\d-\d\d\d' (two sets of 3 digits) will first try to match + '\\d\\d\\d-\\d\\d\\d' (two sets of 3 digits) will first try to match CRE ids before it performs a free text search Anything else will be a case insensitive LIKE query in the database """ @@ -1818,7 +1818,7 @@ def text_search(self, text: str) -> List[Optional[cre_defs.Document]]: node_search = ( r"(Node|(?P" + types - + "))?((:| )?(?Phttps?://\S+))?((:| )(?P.+$))?" + + r"))?((:| )?(?Phttps?://\S+))?((:| )(?P.+$))?" ) match = re.search(cre_id_search, text, re.IGNORECASE) if match: diff --git a/application/web/web_main.py b/application/web/web_main.py index 6738a0109..9350309e0 100644 --- a/application/web/web_main.py +++ b/application/web/web_main.py @@ -465,7 +465,7 @@ def text_search() -> Any: * 'CRE:' will search for the in cre names * 'Standard:[:
:subsection]' will search for all entries of and optionally, section/subsection - * '\d\d\d-\d\d\d' (two sets of 3 digits) will first try to match + * '\\d\\d\\d-\\d\\d\\d' (two sets of 3 digits) will first try to match CRE ids before it performs a free text search Anything else will be a case insensitive LIKE query in the database """