refactor(logging): 统一使用自定义Loger替代g.Log()日志记录
This commit is contained in:
@@ -10,7 +10,6 @@ import (
|
||||
_ "blazing/modules/task/middleware"
|
||||
"blazing/modules/task/model"
|
||||
|
||||
"github.com/gogf/gf/v2/frame/g"
|
||||
"github.com/gogf/gf/v2/os/gctx"
|
||||
)
|
||||
|
||||
@@ -19,7 +18,7 @@ func init() {
|
||||
taskInfo = model.NewTaskInfo()
|
||||
ctx = gctx.GetInitCtx()
|
||||
)
|
||||
g.Log().Debug(ctx, "module task init start ...")
|
||||
cool.Loger.Debug(ctx, "module task init start ...")
|
||||
cool.FillInitData(ctx, "task", taskInfo, nil)
|
||||
|
||||
result, err := cool.DBM(taskInfo).Where("status", 1).All()
|
||||
@@ -30,6 +29,6 @@ func init() {
|
||||
id := v["id"].String()
|
||||
cool.RunFunc(ctx, "TaskAddTask("+id+")")
|
||||
}
|
||||
g.Log().Debug(ctx, "module task init finished ...")
|
||||
cool.Loger.Debug(ctx, "module task init finished ...")
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user