This commit is contained in:
Daniel 2024-11-07 17:38:10 +08:00
parent 831d350653
commit ed33718ddf
No known key found for this signature in database
GPG key ID: 86211BA83DF03017

View file

@ -473,6 +473,10 @@ func buildSearchHistoryQueryFilter(query, op, box, table string, typ int) (stmt
stmt += " AND op = '" + op + "'"
}
if "%" != box && !ast.IsNodeIDPattern(box) {
box = "%"
}
if HistoryTypeDocName == typ || HistoryTypeDoc == typ || HistoryTypeDocID == typ {
if HistoryTypeDocName == typ || HistoryTypeDoc == typ {
stmt += " AND path LIKE '%/" + box + "/%' AND path LIKE '%.sy'"