Files
arenax-server/internal/model/role.go

55 lines
1.3 KiB
Go
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

package model
import "github.com/gogf/gf/v2/frame/g"
// Role 角色信息
type Role struct {
g.Meta `orm:"table:roles"`
Id int64 `json:"id" dc:"角色ID" orm:"id"`
Name string `json:"name" dc:"角色名称" orm:"name"`
Code string `json:"code" dc:"角色编码" orm:"code"`
Description string `json:"description" dc:"角色描述" orm:"description"`
Status int `json:"status" dc:"状态1=启用2=禁用" orm:"status"`
IsDeletable bool `json:"is_deletable" dc:"是否可删除0=不可删除1=可删除" orm:"is_deletable"`
}
// RoleCreateInput 创建角色输入参数
type RoleCreateInput struct {
Name string
Code string
Description string
Status int
}
// RoleUpdateInput 更新角色输入参数
type RoleUpdateInput struct {
Id int64
Name string
Code string
Description string
Status int
}
// RoleListInput 获取角色列表输入参数
type RoleListInput struct {
Page int
Size int
Status int
}
// RoleListOutput 获取角色列表输出参数
type RoleListOutput struct {
List []Role
Total int
}
// RoleGetByIdInput 根据ID获取角色输入参数
type RoleGetByIdInput struct {
Id int64
}
// RoleDeleteInput 删除角色输入参数
type RoleDeleteInput struct {
Id int64
}