Initial commit: web_hghl_server
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
package router
|
||||
|
||||
import (
|
||||
"videoweb/app/api/authapi"
|
||||
|
||||
"github.com/gin-gonic/gin"
|
||||
)
|
||||
|
||||
func authRouter(r *gin.Engine) {
|
||||
// 游客登录(无需 token)
|
||||
login := r.Group("/api/app/login")
|
||||
{
|
||||
login.POST("/guest", authapi.GuestLogin)
|
||||
}
|
||||
|
||||
// 账号注册 / 登录 / 改资料
|
||||
auth := r.Group("/api/app/auth")
|
||||
{
|
||||
auth.POST("/register", authapi.Register)
|
||||
auth.POST("/login", authapi.Login)
|
||||
auth.GET("/getInfo", authapi.GetInfo)
|
||||
auth.POST("/profile", authapi.UpdateProfile)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user