fix: model token creation issue
This commit is contained in:
parent
1c7bad7b87
commit
455643e317
@ -62,11 +62,13 @@ func SetApiRouter(router *gin.Engine) {
|
||||
optionRoute.PUT("/", controller.UpdateOption)
|
||||
}
|
||||
channelRoute := apiRouter.Group("/channel")
|
||||
|
||||
channelRoute.Use(middleware.UserAuth()).GET("/models", controller.ListModels)
|
||||
|
||||
channelRoute.Use(middleware.AdminAuth())
|
||||
{
|
||||
channelRoute.GET("/", controller.GetAllChannels)
|
||||
channelRoute.GET("/search", controller.SearchChannels)
|
||||
channelRoute.GET("/models", controller.ListModels)
|
||||
channelRoute.GET("/:id", controller.GetChannel)
|
||||
channelRoute.GET("/test", controller.TestAllChannels)
|
||||
channelRoute.GET("/test/:id", controller.TestChannel)
|
||||
@ -76,6 +78,7 @@ func SetApiRouter(router *gin.Engine) {
|
||||
channelRoute.PUT("/", controller.UpdateChannel)
|
||||
channelRoute.DELETE("/:id", controller.DeleteChannel)
|
||||
}
|
||||
|
||||
tokenRoute := apiRouter.Group("/token")
|
||||
tokenRoute.Use(middleware.UserAuth())
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user