更新密码找回uniapp

This commit is contained in:
hero920103 committed 2026-11-16 17:22:50 +08:00
1 parent 7f9a66da0f
commit 3fdda89833
1304 files changed
+3503 -26132

No files matched your search

-14
View File
@@ -12,7 +12,6 @@ import (
beego "github.com/beego/beego/v2/server/web"
)
// PlatformAdminUserController 平台管理员用户管理(yz_system_admin_user)
type PlatformAdminUserController struct {
beego.Controller
}
@@ -35,7 +34,6 @@ type adminUserDTO struct {
UpdateTime *string `json:"update_time"`
}
// formatPlatformBirth 空串统一返回 nil,避免前端拿到空字符串
func formatPlatformBirth(birth *string) *string {
if birth == nil {
return nil
@@ -72,8 +70,6 @@ func toAdminUserDTO(u models.AdminUser) adminUserDTO {
}
}
// GetAllUsers 获取全部平台管理员用户
// GET /platform/getAllUsers
func (c *PlatformAdminUserController) GetAllUsers() {
rows, total, err := services.ListAdminUsers()
if err != nil {
@@ -93,8 +89,6 @@ func (c *PlatformAdminUserController) GetAllUsers() {
_ = c.ServeJSON()
}
// GetUserInfo 获取用户详情
// GET /platform/getUserInfo/:id
func (c *PlatformAdminUserController) GetUserInfo() {
idStr := c.Ctx.Input.Param(":id")
id, _ := strconv.ParseUint(idStr, 10, 64)
@@ -131,8 +125,6 @@ type adminAddUserPayload struct {
Status *uint8 `json:"status"`
}
// AddUser 添加平台管理员用户(仅写 yz_system_admin_user,不处理 tid)
// POST /platform/addUser
func (c *PlatformAdminUserController) AddUser() {
var p adminAddUserPayload
raw, _ := io.ReadAll(c.Ctx.Request.Body)
@@ -196,8 +188,6 @@ type editUserPayload struct {
Status *uint8 `json:"status"`
}
// EditUser 编辑用户信息(password 可选,存在则修改)
// POST /platform/editUser/:id
func (c *PlatformAdminUserController) EditUser() {
idStr := c.Ctx.Input.Param(":id")
id, _ := strconv.ParseUint(idStr, 10, 64)
@@ -272,8 +262,6 @@ func (c *PlatformAdminUserController) EditUser() {
_ = c.ServeJSON()
}
// DeleteUser 删除用户
// DELETE /platform/deleteUser/:id
func (c *PlatformAdminUserController) DeleteUser() {
idStr := c.Ctx.Input.Param(":id")
id, _ := strconv.ParseUint(idStr, 10, 64)
@@ -296,8 +284,6 @@ type changePasswordPayload struct {
Password string `json:"password"`
}
// ChangePassword 修改密码
// POST /platform/changePassword
func (c *PlatformAdminUserController) ChangePassword() {
var p changePasswordPayload
raw, _ := io.ReadAll(c.Ctx.Request.Body)