This commit is contained in:
Daniel 2024-12-11 17:43:14 +08:00
parent e70ed57f6e
commit fc47230331
No known key found for this signature in database
GPG key ID: 86211BA83DF03017

View file

@ -1027,6 +1027,7 @@ func FullTextSearchBlock(query string, boxes, paths []string, types map[string]b
boxFilter := buildBoxesFilter(boxes)
pathFilter := buildPathsFilter(paths)
if 2 > len(strings.Split(strings.TrimSpace(query), " ")) {
query = stringQuery(query)
blocks, matchedBlockCount, matchedRootCount = fullTextSearchByQuerySyntax(query, boxFilter, pathFilter, typeFilter, ignoreFilter, orderByClause, beforeLen, page, pageSize)
} else {
docMode = true // 文档全文搜索模式 https://github.com/siyuan-note/siyuan/issues/10584