Skip to content

An open-source, privacy-first, self-hosted knowledge workspace where humans and AI agents work together 开源、隐私优先、自托管的知识工作空间,让人与智能体在此协作

:art: Show count in spaced repetition tree filter floating window https://github.com/siyuan-note/siyuan/issues/8202

Liang Ding8abc00f7f958
diff --git a/kernel/model/flashcard.go b/kernel/model/flashcard.go
index 7e8022c740..78134b5007 100644
--- a/kernel/model/flashcard.go
+++ b/kernel/model/flashcard.go
@@ -59,8 +59,8 @@ func GetFlashcardNotebooks() (ret []*Box) {
func countTreeFlashcard(rootID string, deck *riff.Deck, deckBlockIDs []string) (newFlashcardCount, dueFlashcardCount, flashcardCount int) {
blockIDs := getTreeSubTreeChildBlocks(rootID)
- for _, blockID := range deckBlockIDs {
- if gulu.Str.Contains(blockID, blockIDs) {
+ for _, deckBlockID := range deckBlockIDs {
+ if gulu.Str.Contains(deckBlockID, blockIDs) {
flashcardCount++
}
}
@@ -77,8 +77,8 @@ func countTreeFlashcard(rootID string, deck *riff.Deck, deckBlockIDs []string) (
func countBoxFlashcard(boxID string, deck *riff.Deck, deckBlockIDs []string) (newFlashcardCount, dueFlashcardCount, flashcardCount int) {
blockIDs := getBoxBlocks(boxID)
- for _, blockID := range deckBlockIDs {
- if gulu.Str.Contains(blockID, blockIDs) {
+ for _, deckBlockID := range deckBlockIDs {
+ if gulu.Str.Contains(deckBlockID, blockIDs) {
flashcardCount++
}
}