实现代理网关管理接口
This commit is contained in:
@@ -25,7 +25,6 @@ func ApplyRouters(app *fiber.App) {
|
||||
if env.RunMode == env.RunModeDev {
|
||||
debug := app.Group("/debug")
|
||||
debug.Get("/sms/:phone", handlers.DebugGetSmsCode)
|
||||
debug.Get("/proxy/register", handlers.DebugRegisterProxyBaiYin)
|
||||
debug.Get("/iden/clear/:phone", handlers.DebugIdentifyClear)
|
||||
debug.Get("/session/now", func(ctx *fiber.Ctx) error {
|
||||
rs, err := q.Session.Where(q.Session.AccessTokenExpires.Gt(time.Now())).Find()
|
||||
@@ -134,9 +133,6 @@ func clientRouter(api fiber.Router) {
|
||||
channel := client.Group("/channel")
|
||||
channel.Post("/remove", handlers.RemoveChannels)
|
||||
|
||||
// 代理网关注册
|
||||
proxy := client.Group("/proxy")
|
||||
proxy.Post("/register/baidyin", handlers.ProxyRegisterBaiYin)
|
||||
}
|
||||
|
||||
// 管理员接口路由
|
||||
@@ -196,6 +192,15 @@ func adminRouter(api fiber.Router) {
|
||||
channel.Post("/page", handlers.PageChannelByAdmin)
|
||||
channel.Post("/page/of-user", handlers.PageChannelOfUserByAdmin)
|
||||
|
||||
// proxy 代理
|
||||
var proxy = api.Group("/proxy")
|
||||
proxy.Post("/all", handlers.AllProxyByAdmin)
|
||||
proxy.Post("/page", handlers.PageProxyByAdmin)
|
||||
proxy.Post("/create", handlers.CreateProxy)
|
||||
proxy.Post("/update", handlers.UpdateProxy)
|
||||
proxy.Post("/update/status", handlers.UpdateProxyStatus)
|
||||
proxy.Post("/remove", handlers.RemoveProxy)
|
||||
|
||||
// trade 交易
|
||||
var trade = api.Group("/trade")
|
||||
trade.Post("/page", handlers.PageTradeByAdmin)
|
||||
|
||||
Reference in New Issue
Block a user