This commit is contained in:
Daniel 2024-09-18 11:28:04 +08:00
parent 4f31068205
commit 827819ef67
No known key found for this signature in database
GPG key ID: 86211BA83DF03017
4 changed files with 29 additions and 7 deletions

View file

@ -38,8 +38,13 @@ func getDocOutline(c *gin.Context) {
return
}
preview := false
if previewArg := arg["preview"]; nil != previewArg {
preview = previewArg.(bool)
}
rootID := arg["id"].(string)
headings, err := model.Outline(rootID)
headings, err := model.Outline(rootID, preview)
if err != nil {
ret.Code = 1
ret.Msg = err.Error()