This commit is contained in:
shaoyongjun 2024-05-15 14:24:48 +08:00
parent 64ec45e822
commit b7d00e0a9b

View File

@ -14,7 +14,7 @@ import (
func InitUserGroup(g *echo.Group) {
//注册
g.POST("user/register", func(c echo.Context) error {
g.POST("register", func(c echo.Context) error {
req := new(dto.ThirdRegisterReq)
if err := c.Bind(req); err != nil {
return c.JSON(http.StatusOK, utils.Error(err))
@ -37,7 +37,7 @@ func InitUserGroup(g *echo.Group) {
})
//登录
g.POST("user/login", func(c echo.Context) error {
g.POST("login", func(c echo.Context) error {
req := new(dto.ThirdLoginReq)
if err := c.Bind(req); err != nil {
return c.JSON(http.StatusOK, utils.Error(err))
@ -54,7 +54,7 @@ func InitUserGroup(g *echo.Group) {
})
//发送 重置密码 验证码
g.POST("user/sendResetPwdCode", func(c echo.Context) error {
g.POST("sendResetPwdCode", func(c echo.Context) error {
req := new(dto.SendResetPwdCodeReq)
if err := c.Bind(req); err != nil {
return c.JSON(http.StatusOK, utils.Error(err))
@ -69,7 +69,7 @@ func InitUserGroup(g *echo.Group) {
})
//重置密码
g.POST("user/resetPwd", func(c echo.Context) error {
g.POST("resetPwd", func(c echo.Context) error {
req := new(dto.ThirdResetPwdReq)
if err := c.Bind(req); err != nil {
return c.JSON(http.StatusOK, utils.Error(err))