This commit is contained in:
coward
2024-07-05 14:41:35 +08:00
commit 1f7f57ec9f
70 changed files with 4923 additions and 0 deletions

View File

@@ -0,0 +1,22 @@
package constant
// UserType 用户类型
type UserType int
const (
NormalAdmin UserType = iota
SuperAdmin
)
var UserTypeMap = map[UserType]string{
NormalAdmin: "普通管理员",
SuperAdmin: "超级管理员",
}
func (u UserType) String() string {
if v, ok := UserTypeMap[u]; ok {
return v
}
return "未知类型"
}