feat: 添加鉴权组件

This commit is contained in:
lixiangwuxian
2024-10-20 01:24:45 +08:00
parent 0efdd71c8a
commit b1fa836304
4 changed files with 72 additions and 2 deletions

8
constants/auth.go Normal file
View File

@@ -0,0 +1,8 @@
package constants
const (
LEVEL_ROOT = 0
LEVEL_ADMIN = 10
LEVEL_USER = 20 //default
LEVEL_BANNED = 100
)