提交 35661ff7 编写于 作者: Mr.奇淼('s avatar Mr.奇淼(

增加了 配置管理功能

上级 2c0ba7ef
......@@ -22,7 +22,6 @@ func GetSystemConfig(c *gin.Context) {
}
}
// @Tags system
// @Summary 设置配置文件内容
// @Security ApiKeyAuth
......@@ -40,22 +39,3 @@ func SetSystemConfig(c *gin.Context) {
servers.ReportFormat(c, true, "设置成功", gin.H{})
}
}
// @Tags system
// @Summary 设置配置文件内容
// @Security ApiKeyAuth
// @Produce application/json
// @Param data body sysModel.System true
// @Success 200 {string} string "{"success":true,"data":{},"msg":"返回成功"}"
// @Router /system/ReloadSystem [post]
func ReloadSystem(c *gin.Context) {
var sys sysModel.System
_ = c.ShouldBind(&sys)
err := sys.SetSystemConfig()
if err != nil {
servers.ReportFormat(c, false, fmt.Sprintf("设置失败:%v", err), gin.H{})
} else {
servers.ReportFormat(c, true, "设置成功", gin.H{})
}
}
\ No newline at end of file
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册