mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-02-11 17:54:20 +01:00
⚡ Improve performance for rendering databases, due flashcards
This commit is contained in:
parent
65f24b376e
commit
06f3721fd4
6 changed files with 36 additions and 7 deletions
|
|
@ -199,7 +199,7 @@ func GetAttributeViewPrimaryKeyValues(avID, keyword string, page, pageSize int)
|
|||
switch view.LayoutType {
|
||||
case av.LayoutTypeTable:
|
||||
if !kv.IsDetached {
|
||||
if nil == treenode.GetBlockTree(kv.BlockID) {
|
||||
if !treenode.ExistBlockTree(kv.BlockID) {
|
||||
break
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -71,17 +71,17 @@ func GetDocInfo(blockID string) (ret *BlockInfo) {
|
|||
delete(ret.IAL, "scroll")
|
||||
} else {
|
||||
if zoomInId := scroll["zoomInId"]; nil != zoomInId {
|
||||
if nil == treenode.GetBlockTree(zoomInId.(string)) {
|
||||
if !treenode.ExistBlockTree(zoomInId.(string)) {
|
||||
delete(ret.IAL, "scroll")
|
||||
}
|
||||
} else {
|
||||
if startId := scroll["startId"]; nil != startId {
|
||||
if nil == treenode.GetBlockTree(startId.(string)) {
|
||||
if !treenode.ExistBlockTree(startId.(string)) {
|
||||
delete(ret.IAL, "scroll")
|
||||
}
|
||||
}
|
||||
if endId := scroll["endId"]; nil != endId {
|
||||
if nil == treenode.GetBlockTree(endId.(string)) {
|
||||
if !treenode.ExistBlockTree(endId.(string)) {
|
||||
delete(ret.IAL, "scroll")
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1085,7 +1085,7 @@ func getDeckDueCards(deck *riff.Deck, reviewedCardIDs, blockIDs []string, newCar
|
|||
continue
|
||||
}
|
||||
|
||||
if nil == treenode.GetBlockTree(c.BlockID()) {
|
||||
if !treenode.ExistBlockTree(c.BlockID()) {
|
||||
continue
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue