mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-03-11 23:22:33 +01:00
🎨 Supports searching database blocks by the view title https://github.com/siyuan-note/siyuan/issues/9348
This commit is contained in:
parent
cf154dcaa1
commit
d38311c48c
5 changed files with 40 additions and 28 deletions
|
|
@ -22,6 +22,7 @@ import (
|
|||
"encoding/json"
|
||||
"errors"
|
||||
"fmt"
|
||||
"github.com/siyuan-note/siyuan/kernel/av"
|
||||
"image"
|
||||
"image/jpeg"
|
||||
"image/png"
|
||||
|
|
@ -154,7 +155,7 @@ func ImportSY(zipPath, boxID, toPath string) (err error) {
|
|||
// 重新指向数据库属性值
|
||||
ial := parse.IAL2Map(n.KramdownIAL)
|
||||
for k, _ := range ial {
|
||||
if strings.HasPrefix(k, NodeAttrNameAvs) {
|
||||
if strings.HasPrefix(k, av.NodeAttrNameAvs) {
|
||||
avBlockIDs[oldNodeID] = newNodeID
|
||||
}
|
||||
}
|
||||
|
|
@ -257,7 +258,7 @@ func ImportSY(zipPath, boxID, toPath string) (err error) {
|
|||
|
||||
ial := parse.IAL2Map(n.KramdownIAL)
|
||||
for k, v := range ial {
|
||||
if strings.HasPrefix(k, NodeAttrNameAvs) {
|
||||
if strings.HasPrefix(k, av.NodeAttrNameAvs) {
|
||||
newKey, newVal := k, v
|
||||
for oldAvID, newAvID := range avIDs {
|
||||
newKey = strings.ReplaceAll(newKey, oldAvID, newAvID)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue