mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-01-24 17:26:10 +01:00
🎨 Subdocuments created by the database are not displayed in the doc tree https://github.com/siyuan-note/siyuan/issues/9091
This commit is contained in:
parent
830c8b55cf
commit
756d1ed4c0
3 changed files with 24 additions and 13 deletions
|
|
@ -481,6 +481,12 @@ func createDocWithMd(c *gin.Context) {
|
|||
parentID = parentIDArg.(string)
|
||||
}
|
||||
|
||||
showInDocTree := true
|
||||
showInDocTreeArg := arg["showInDocTree"]
|
||||
if nil != showInDocTreeArg {
|
||||
showInDocTree = showInDocTreeArg.(bool)
|
||||
}
|
||||
|
||||
hPath := arg["path"].(string)
|
||||
markdown := arg["markdown"].(string)
|
||||
|
||||
|
|
@ -496,7 +502,7 @@ func createDocWithMd(c *gin.Context) {
|
|||
hPath = "/" + hPath
|
||||
}
|
||||
|
||||
id, err := model.CreateWithMarkdown(notebook, hPath, markdown, parentID)
|
||||
id, err := model.CreateWithMarkdown(notebook, hPath, markdown, parentID, showInDocTree)
|
||||
if nil != err {
|
||||
ret.Code = -1
|
||||
ret.Msg = err.Error()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue