模块化定时任务,方便在插件中注册任务;增加日志分组

This commit is contained in:
孟帅
2023-06-05 20:14:57 +08:00
parent 62ecbb7f26
commit 48f8c20d9c
79 changed files with 820 additions and 783 deletions

View File

@@ -27,6 +27,7 @@ type ViewReq struct {
g.Meta `path:"/cron/view" method:"get" tags:"定时任务" summary:"获取指定信息"`
sysin.CronViewInp
}
type ViewRes struct {
*sysin.CronViewModel
}
@@ -36,6 +37,7 @@ type EditReq struct {
g.Meta `path:"/cron/edit" method:"post" tags:"定时任务" summary:"修改/新增定时任务"`
sysin.CronEditInp
}
type EditRes struct {
*sysin.CronEditModel
}
@@ -45,6 +47,7 @@ type DeleteReq struct {
g.Meta `path:"/cron/delete" method:"post" tags:"定时任务" summary:"删除定时任务"`
sysin.CronDeleteInp
}
type DeleteRes struct {
*sysin.CronDeleteModel
}
@@ -54,6 +57,7 @@ type MaxSortReq struct {
g.Meta `path:"/cron/maxSort" method:"get" tags:"定时任务" summary:"定时任务最大排序"`
sysin.CronMaxSortInp
}
type MaxSortRes struct {
*sysin.CronMaxSortModel
}
@@ -63,6 +67,7 @@ type StatusReq struct {
g.Meta `path:"/cron/status" method:"post" tags:"定时任务" summary:"更新定时任务状态"`
sysin.CronStatusInp
}
type StatusRes struct {
*sysin.CronStatusModel
}
@@ -72,6 +77,7 @@ type OnlineExecReq struct {
g.Meta `path:"/cron/onlineExec" method:"post" tags:"定时任务" summary:"在线执行"`
sysin.OnlineExecInp
}
type OnlineExecRes struct {
*sysin.OnlineExecModel
}

View File

@@ -7,7 +7,6 @@ package cron
import (
"github.com/gogf/gf/v2/frame/g"
"hotgo/internal/model/entity"
"hotgo/internal/model/input/form"
"hotgo/internal/model/input/sysin"
)
@@ -28,6 +27,7 @@ type GroupViewReq struct {
g.Meta `path:"/cronGroup/view" method:"get" tags:"定时任务分组" summary:"获取指定信息"`
sysin.CronGroupViewInp
}
type GroupViewRes struct {
*sysin.CronGroupViewModel
}
@@ -37,6 +37,7 @@ type GroupEditReq struct {
g.Meta `path:"/cronGroup/edit" method:"post" tags:"定时任务分组" summary:"修改/新增定时任务分组"`
sysin.CronGroupEditInp
}
type GroupEditRes struct {
*sysin.CronGroupEditModel
}
@@ -46,6 +47,7 @@ type GroupDeleteReq struct {
g.Meta `path:"/cronGroup/delete" method:"post" tags:"定时任务分组" summary:"删除定时任务分组"`
sysin.CronGroupDeleteInp
}
type GroupDeleteRes struct {
*sysin.CronGroupDeleteModel
}
@@ -55,16 +57,17 @@ type GroupMaxSortReq struct {
g.Meta `path:"/cronGroup/maxSort" method:"get" tags:"定时任务分组" summary:"定时任务分组最大排序"`
sysin.CronGroupMaxSortInp
}
type GroupMaxSortRes struct {
*sysin.CronGroupMaxSortModel
}
// GroupStatusReq 更新状态
type GroupStatusReq struct {
entity.SysCronGroup
g.Meta `path:"/cronGroup/status" method:"post" tags:"定时任务分组" summary:"更新定时任务分组状态"`
sysin.CronGroupStatusInp
}
type GroupStatusRes struct {
*sysin.CronGroupStatusModel
}