auth.go 503 B

1234567891011121314151617
  1. package routers
  2. import (
  3. "github.com/gin-gonic/gin"
  4. "hongze/hongze_yb_en_api/controller"
  5. )
  6. func InitAuth(baseGroup *gin.RouterGroup) {
  7. //登录
  8. authController := new(controller.AuthController)
  9. authGroup := baseGroup.Group("auth/")
  10. authGroup.POST("login", authController.Login)
  11. authGroup.POST("register", authController.Register)
  12. authGroup.POST("modifyPwd", authController.Login)
  13. authGroup.POST("smsCode", authController.GetSmsCode)
  14. authGroup.POST("emailCode", authController.GetEmailCode)
  15. }