mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-02-28 05:32:52 +00:00
✨ Support for searching asset content https://github.com/siyuan-note/siyuan/issues/8874
This commit is contained in:
@@ -143,7 +143,7 @@ func assetContentFieldRegexp(exp string) string {
|
||||
|
||||
func fullTextSearchAssetContentCountByRegexp(exp, typeFilter string) (matchedAssetCount int) {
|
||||
table := "asset_contents_fts_case_insensitive"
|
||||
fieldFilter := fieldRegexp(exp)
|
||||
fieldFilter := assetContentFieldRegexp(exp)
|
||||
stmt := "SELECT COUNT(path) AS `assets` FROM `" + table + "` WHERE " + fieldFilter + " AND ext IN " + typeFilter
|
||||
result, _ := sql.QueryAssetContentNoLimit(stmt)
|
||||
if 1 > len(result) {
|
||||
|
||||
Reference in New Issue
Block a user