mirror of
https://gitee.com/XM-GO/PandaX.git
synced 2026-04-23 10:58:35 +08:00
项目目录优化,任务模块后端代码
This commit is contained in:
22
apps/system/api/form/role.go
Normal file
22
apps/system/api/form/role.go
Normal file
@@ -0,0 +1,22 @@
|
||||
package form
|
||||
|
||||
// 分配角色资源表单信息
|
||||
type RoleResourceForm struct {
|
||||
Id int
|
||||
ResourceIds string
|
||||
}
|
||||
|
||||
// 保存角色信息表单
|
||||
type RoleForm struct {
|
||||
Id int
|
||||
Status int `json:"status"` // 1:可用;-1:不可用
|
||||
Name string `binding:"required"`
|
||||
Code string `binding:"required"`
|
||||
Remark string `json:"remark"`
|
||||
}
|
||||
|
||||
// 账号分配角色表单
|
||||
type AccountRoleForm struct {
|
||||
Id int `binding:"required"`
|
||||
RoleIds string
|
||||
}
|
||||
34
apps/system/api/form/user.go
Normal file
34
apps/system/api/form/user.go
Normal file
@@ -0,0 +1,34 @@
|
||||
package form
|
||||
|
||||
// User register structure
|
||||
type Register struct {
|
||||
Username string `json:"userName"`
|
||||
Password string `json:"passWord"`
|
||||
NickName string `json:"nickName" gorm:"default:'QMPlusUser'"`
|
||||
HeaderImg string `json:"headerImg" gorm:"default:'http://www.henrongyi.top/avatar/lufu.jpg'"`
|
||||
AuthorityId string `json:"authorityId" gorm:"default:888"`
|
||||
}
|
||||
|
||||
// User login structure
|
||||
type Login struct {
|
||||
Username string `json:"username"` // 用户名
|
||||
Password string `json:"password"` // 密码
|
||||
Captcha string `json:"captcha"` // 验证码
|
||||
CaptchaId string `json:"captchaId"` // 验证码ID
|
||||
}
|
||||
|
||||
// Modify password structure
|
||||
type ChangePasswordStruct struct {
|
||||
Username string `json:"username"` // 用户名
|
||||
Password string `json:"password"` // 密码
|
||||
NewPassword string `json:"newPassword"` // 新密码
|
||||
}
|
||||
|
||||
type UserSearch struct {
|
||||
Username string `json:"username"` // 用户UUID
|
||||
NickName string `json:"nickName"` // 角色ID
|
||||
Status int64 `json:"status"` // 角色ID
|
||||
Phone string `json:"phone"` // 角色ID
|
||||
PostId int64 `json:"postId"` // 角色ID
|
||||
DeptId int64 `json:"deptId"` // 角色ID
|
||||
}
|
||||
Reference in New Issue
Block a user