chore: change xxl-job name

This commit is contained in:
RockYang 2023-11-12 15:39:12 +08:00
parent 51407abe44
commit e311a39632
2 changed files with 4 additions and 3 deletions

View File

@ -38,13 +38,13 @@ func NewXXLJobExecutor(config *types.AppConfig, db *gorm.DB) *XXLJobExecutor {
}
func (e *XXLJobExecutor) Run() error {
e.executor.RegTask("ClearOrder", e.ClearOrder)
e.executor.RegTask("ClearOrders", e.ClearOrders)
e.executor.RegTask("ResetVipCalls", e.ResetVipCalls)
return e.executor.Run()
}
// ClearOrder 清理未支付的订单,如果没有抛出异常则表示执行成功
func (e *XXLJobExecutor) ClearOrder(cxt context.Context, param *xxl.RunReq) (msg string) {
// ClearOrders 清理未支付的订单,如果没有抛出异常则表示执行成功
func (e *XXLJobExecutor) ClearOrders(cxt context.Context, param *xxl.RunReq) (msg string) {
logger.Debug("执行清理未支付订单...")
var sysConfig model.Config
res := e.db.Where("marker", "system").First(&sysConfig)

View File

@ -11,6 +11,7 @@ services:
- CONFIG_FILE=config.toml
ports:
- "5678:5678"
- "9999:9999"
volumes:
- /usr/share/zoneinfo/Asia/Shanghai:/etc/localtime
- ./conf/config.toml:/var/www/app/config.toml