Documentation ¶
Overview ¶
* 权限相关API
Index ¶
- func AddPermission(QID int64, Level int64) error
- func BanUser(QID int64) error
- func CheckPermissions(QID int64, minLevel int64) (bool, error)
- func IsBaned(QID int64) (bool, error)
- func QueryLastPermission(QID int64) (int64, error)
- func QueryPermission(QID int64) (int64, error)
- func RemovePermission(QID int64) error
- func ResetUserLevel(QID int64) error
- func RestAllLevel() error
- func UnbanUser(QID int64) error
- func UpdatePermission(QID int64, Level int64) error
- type PermissionConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddPermission ¶
func QueryLastPermission ¶
func QueryPermission ¶
func RemovePermission ¶
func ResetUserLevel ¶
func RestAllLevel ¶
func RestAllLevel() error
func UpdatePermission ¶
Types ¶
type PermissionConfig ¶
type PermissionConfig struct {
MinLevel int64 `yaml:"DefaultLevel"`
}
默认权限设置结构体
Click to show internal directories.
Click to hide internal directories.