上传网关日志开关

This commit is contained in:
liwei1dao 2022-07-13 15:50:19 +08:00
parent acbeae031c
commit c251a63adc
2 changed files with 4 additions and 4 deletions

View File

@ -10,7 +10,9 @@ import (
type (
Options struct {
ListenPort int //websocket 监听端口
Debug bool //日志开关
GinDebug bool //web引擎日志开关
ListenPort int //websocket 监听端口
}
)

View File

@ -25,11 +25,9 @@ func (this *WSServiceComp) Init(service core.IService, module core.IModule, comp
err = this.ModuleCompBase.Init(service, module, comp, options)
this.options = options.(*Options)
this.module = module.(IGateway)
this.gin, err = gin.NewSys(gin.SetListenPort(this.options.ListenPort))
this.gin, err = gin.NewSys(gin.SetListenPort(this.options.ListenPort), gin.SetDebug(this.options.GinDebug))
// 游戏业务逻辑处理
this.gin.GET("/gateway", this.ws)
return
}