package routers import ( "github.com/beego/beego/v2/server/web" "github.com/linmadan/egglib-go/web/beego/filters" "gitlab.fjmaimaimai.com/allied-creation/performance/pkg/port/beego/controllers" "gitlab.fjmaimaimai.com/allied-creation/performance/pkg/port/beego/middlewares" ) func init() { ns := web.NewNamespace("/v1/import", web.NSBefore(filters.AllowCors(), middlewares.CheckAdminToken()), web.NSRouter("/", &controllers.ImportController{}, "Post:Import"), web.NSRouter("/zip", &controllers.ImportController{}, "Post:ZipImport"), web.NSRouter("/zip-verify", &controllers.ImportController{}, "Post:ZipVerify"), ) web.AddNamespace(ns) }