gin-vue-admin 2.0代码重构
This commit is contained in:
17
server/router/sys_base.go
Normal file
17
server/router/sys_base.go
Normal file
@@ -0,0 +1,17 @@
|
||||
package router
|
||||
|
||||
import (
|
||||
"gin-vue-admin/api/v1"
|
||||
"github.com/gin-gonic/gin"
|
||||
)
|
||||
|
||||
func InitBaseRouter(Router *gin.RouterGroup) (R gin.IRoutes) {
|
||||
BaseRouter := Router.Group("base")
|
||||
{
|
||||
BaseRouter.POST("register", v1.Register)
|
||||
BaseRouter.POST("login", v1.Login)
|
||||
BaseRouter.POST("captcha", v1.Captcha)
|
||||
BaseRouter.GET("captcha/:captchaId", v1.CaptchaImg)
|
||||
}
|
||||
return BaseRouter
|
||||
}
|
Reference in New Issue
Block a user