🎨 Rebuilding database block relations when importing .sy.zip and rebuilding indexes https://github.com/siyuan-note/siyuan/issues/10959

This commit is contained in:
Daniel 2024-04-09 22:26:18 +08:00
parent c4d2f9e706
commit 7d680ed391
No known key found for this signature in database
GPG key ID: 86211BA83DF03017
2 changed files with 13 additions and 0 deletions

View file

@ -281,6 +281,10 @@ func ImportSY(zipPath, boxID, toPath string) (err error) {
}
return ast.WalkContinue
})
// 关联数据库和块
avNodes := tree.Root.ChildrenByType(ast.NodeAttributeView)
av.BatchUpsertBlockRel(avNodes)
}
}