Merge remote-tracking branch 'origin/dev' into dev

This commit is contained in:
Vanessa 2023-12-06 16:51:58 +08:00
commit dcee5e54c7
4 changed files with 16 additions and 6 deletions

View file

@ -306,6 +306,7 @@ func ServeAPI(ginServer *gin.Engine) {
ginServer.Handle("POST", "/api/setting/setFlashcard", model.CheckAuth, model.CheckReadonly, setFlashcard)
ginServer.Handle("POST", "/api/setting/setAI", model.CheckAuth, model.CheckReadonly, setAI)
ginServer.Handle("POST", "/api/setting/setBazaar", model.CheckAuth, model.CheckReadonly, setBazaar)
ginServer.Handle("POST", "/api/setting/refreshVirtualBlockRef", model.CheckAuth, model.CheckReadonly, refreshVirtualBlockRef)
ginServer.Handle("POST", "/api/graph/resetGraph", model.CheckAuth, model.CheckReadonly, resetGraph)
ginServer.Handle("POST", "/api/graph/resetLocalGraph", model.CheckAuth, model.CheckReadonly, resetLocalGraph)

View file

@ -29,6 +29,15 @@ import (
"github.com/siyuan-note/siyuan/kernel/util"
)
func refreshVirtualBlockRef(c *gin.Context) {
// Add internal kernel API `/api/setting/refreshVirtualBlockRef` https://github.com/siyuan-note/siyuan/issues/9829
ret := gulu.Ret.NewResult()
defer c.JSON(http.StatusOK, ret)
model.ResetVirtualBlockRefCache()
}
func setBazaar(c *gin.Context) {
ret := gulu.Ret.NewResult()
defer c.JSON(http.StatusOK, ret)

View file

@ -50,10 +50,10 @@ require (
github.com/rqlite/sql v0.0.0-20221103124402-8f9ff0ceb8f0
github.com/sashabaranov/go-openai v1.17.9
github.com/shirou/gopsutil/v3 v3.23.10
github.com/siyuan-note/dejavu v0.0.0-20231205130506-f108e3e9e55b
github.com/siyuan-note/dejavu v0.0.0-20231206081926-c2bda200c8ab
github.com/siyuan-note/encryption v0.0.0-20220713091850-5ecd92177b75
github.com/siyuan-note/eventbus v0.0.0-20230804030110-cf250f838c80
github.com/siyuan-note/filelock v0.0.0-20231205130315-1fc852fc9fb1
github.com/siyuan-note/filelock v0.0.0-20231206081043-b75b363ddb1b
github.com/siyuan-note/httpclient v0.0.0-20231120083123-750db4d28b38
github.com/siyuan-note/logging v0.0.0-20231030034701-8265764f00ff
github.com/siyuan-note/riff v0.0.0-20231128081053-0cd7a5fa0076

View file

@ -356,14 +356,14 @@ github.com/shopspring/decimal v1.3.1/go.mod h1:DKyhrW/HYNuLGql+MJL6WCR6knT2jwCFR
github.com/shurcooL/gofontwoff v0.0.0-20181114050219-180f79e6909d h1:lvCTyBbr36+tqMccdGMwuEU+hjux/zL6xSmf5S9ITaA=
github.com/shurcooL/gofontwoff v0.0.0-20181114050219-180f79e6909d/go.mod h1:05UtEgK5zq39gLST6uB0cf3NEHjETfB4Fgr3Gx5R9Vw=
github.com/simplereach/timeutils v1.2.0/go.mod h1:VVbQDfN/FHRZa1LSqcwo4kNZ62OOyqLLGQKYB3pB0Q8=
github.com/siyuan-note/dejavu v0.0.0-20231205130506-f108e3e9e55b h1:Fe8/MKezRTaq7/8k0O8TGtopAuAW6Sxz0d1WjTylry4=
github.com/siyuan-note/dejavu v0.0.0-20231205130506-f108e3e9e55b/go.mod h1:5r1o1fbWam7+QaIHdbMhRhWTdxOemmxiNw1y7bjKHfc=
github.com/siyuan-note/dejavu v0.0.0-20231206081926-c2bda200c8ab h1:yrHnTwFWgjjWBxPiOjpS+l64IDgfL2wPMSo6BJbcpB0=
github.com/siyuan-note/dejavu v0.0.0-20231206081926-c2bda200c8ab/go.mod h1:tcmM806ypoV+j+LXHkeGvYcWMGzTg1h2qqrxjish5DQ=
github.com/siyuan-note/encryption v0.0.0-20220713091850-5ecd92177b75 h1:Bi7/7f29LW+Fm0cHc0J1NO1cZqyJwljSWVmfOqVZgaE=
github.com/siyuan-note/encryption v0.0.0-20220713091850-5ecd92177b75/go.mod h1:H8fyqqAbp9XreANjeSbc72zEdFfKTXYN34tc1TjZwtw=
github.com/siyuan-note/eventbus v0.0.0-20230804030110-cf250f838c80 h1:XghjHKJd+SiL0DkGYFVC+UGUDFtnR4v9gkAbPeh9Eq8=
github.com/siyuan-note/eventbus v0.0.0-20230804030110-cf250f838c80/go.mod h1:Sqo4FYX5lAXu7gWkbEdJF0e6P57tNNVV4WDKYDctokI=
github.com/siyuan-note/filelock v0.0.0-20231205130315-1fc852fc9fb1 h1:PW8T17xlL7MQ7erZi0alO5ehBpF0WtLk/kTAtJ4fhAg=
github.com/siyuan-note/filelock v0.0.0-20231205130315-1fc852fc9fb1/go.mod h1:4teUA+79ESPDbagztng2dJfyv66pGrri5ldGJQG/saI=
github.com/siyuan-note/filelock v0.0.0-20231206081043-b75b363ddb1b h1:zl/gZ/6emGWvyIQSrs/au/2K4pnVnu0hgGjH29RfoXM=
github.com/siyuan-note/filelock v0.0.0-20231206081043-b75b363ddb1b/go.mod h1:4teUA+79ESPDbagztng2dJfyv66pGrri5ldGJQG/saI=
github.com/siyuan-note/httpclient v0.0.0-20231120083123-750db4d28b38 h1:deUrbUOwmsNYRT0x12GHaJ8exxmDMwXFL/1J4dVnLMM=
github.com/siyuan-note/httpclient v0.0.0-20231120083123-750db4d28b38/go.mod h1:QOTSBBSeKU90Kb4aeDVcQ0G+2zJcNuhkwAlsJ2cnmkQ=
github.com/siyuan-note/logging v0.0.0-20231030034701-8265764f00ff h1:5GcxrTOJTsusXOLhg4GuHWbEa4M5gu+CNfL0giwNjDM=