feat(thumb): generator settings and test button

This commit is contained in:
Aaron Liu
2023-04-07 19:33:02 +08:00
parent ac536408c6
commit cf03206283
5 changed files with 114 additions and 2 deletions

View File

@@ -98,6 +98,17 @@ func AdminSendTestMail(c *gin.Context) {
}
}
// AdminTestThumbGenerator Tests thumb generator
func AdminTestThumbGenerator(c *gin.Context) {
var service admin.ThumbGeneratorTestService
if err := c.ShouldBindJSON(&service); err == nil {
res := service.Test(c)
c.JSON(200, res)
} else {
c.JSON(200, ErrorResponse(err))
}
}
// AdminTestAria2 测试aria2连接
func AdminTestAria2(c *gin.Context) {
var service admin.Aria2TestService