mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-17 07:00:12 +01:00
🐛 默认闪卡包移除后卡住 Fix https://github.com/siyuan-note/siyuan/issues/6946
This commit is contained in:
parent
7797750ae8
commit
c4ba046898
3 changed files with 19 additions and 34 deletions
|
|
@ -27,7 +27,7 @@ import (
|
|||
"github.com/siyuan-note/siyuan/kernel/util"
|
||||
)
|
||||
|
||||
func renderRiffCard(c *gin.Context) {
|
||||
func searchRiffCards(c *gin.Context) {
|
||||
ret := gulu.Ret.NewResult()
|
||||
defer c.JSON(http.StatusOK, ret)
|
||||
|
||||
|
|
@ -36,16 +36,10 @@ func renderRiffCard(c *gin.Context) {
|
|||
return
|
||||
}
|
||||
|
||||
blockID := arg["blockID"].(string)
|
||||
content, err := model.RenderFlashcard(blockID)
|
||||
if nil != err {
|
||||
ret.Code = -1
|
||||
ret.Msg = err.Error()
|
||||
return
|
||||
}
|
||||
|
||||
deckID := arg["deckID"].(string)
|
||||
blockIDs := model.SearchFlashcard(deckID)
|
||||
ret.Data = map[string]interface{}{
|
||||
"content": content,
|
||||
"blockIDs": blockIDs,
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue