18 lines
325 B
Go
18 lines
325 B
Go
|
package route
|
||
|
|
||
|
import (
|
||
|
"github.com/gin-gonic/gin"
|
||
|
"go_api_tmpl/core"
|
||
|
)
|
||
|
|
||
|
func InitRoute(app *gin.Engine) {
|
||
|
app.GET("/", func(context *gin.Context) {
|
||
|
core.R(context).OkWithMessage("瞅啥呢?")
|
||
|
})
|
||
|
group := app.Group("/api")
|
||
|
// 登录相关接口路由
|
||
|
initLoginRoute(group)
|
||
|
// 测试用的
|
||
|
initTestRoute(group)
|
||
|
}
|