mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-02-25 08:24:06 +01:00
🎨 Windows/macOS 桌面端支持开机启动 https://github.com/siyuan-note/siyuan/issues/6833
This commit is contained in:
parent
ad1924890b
commit
5a4b64464d
9 changed files with 43 additions and 2 deletions
|
|
@ -333,6 +333,20 @@ func setUploadErrLog(c *gin.Context) {
|
|||
time.Sleep(time.Second * 3)
|
||||
}
|
||||
|
||||
func setAutoLaunch(c *gin.Context) {
|
||||
ret := gulu.Ret.NewResult()
|
||||
defer c.JSON(http.StatusOK, ret)
|
||||
|
||||
arg, ok := util.JsonArg(c, ret)
|
||||
if !ok {
|
||||
return
|
||||
}
|
||||
|
||||
autoLaunch := arg["autoLaunch"].(bool)
|
||||
model.Conf.System.AutoLaunch = autoLaunch
|
||||
model.Conf.Save()
|
||||
}
|
||||
|
||||
func setDownloadInstallPkg(c *gin.Context) {
|
||||
ret := gulu.Ret.NewResult()
|
||||
defer c.JSON(http.StatusOK, ret)
|
||||
|
|
|
|||
|
|
@ -41,6 +41,7 @@ type System struct {
|
|||
UploadErrLog bool `json:"uploadErrLog"`
|
||||
DisableGoogleAnalytics bool `json:"disableGoogleAnalytics"`
|
||||
DownloadInstallPkg bool `json:"downloadInstallPkg"`
|
||||
AutoLaunch bool `json:"autoLaunch"`
|
||||
}
|
||||
|
||||
func NewSystem() *System {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue