feat: 去掉跨域,在网关统一做跨域处理
This commit is contained in:
@@ -22,7 +22,7 @@ type Router struct{}
|
||||
|
||||
func (router *Router) BindController(ctx context.Context, group *ghttp.RouterGroup) {
|
||||
group.Group("/api/v1", func(group *ghttp.RouterGroup) {
|
||||
//跨域处理,安全起见正式环境请注释该行
|
||||
//跨域处理,安全起见正式环境请注释该行(在网关统一处理跨域问题)
|
||||
//group.Middleware(commonService.Middleware().MiddlewareCORS)
|
||||
group.Middleware(ghttp.MiddlewareHandlerResponse)
|
||||
// 绑定后台路由
|
||||
|
||||
Reference in New Issue
Block a user