Documentation ¶
Index ¶
- Constants
- func AdminerStatusNames() map[uint8]string
- func DB() *gorm.DB
- func HasAdminer(username string) bool
- func InitDB()
- func LogTypeNames() map[int]string
- func PermissionTypeNames() map[uint8]string
- type Adminer
- type Cache
- type Config
- type Log
- type Permission
- type PermissionGroup
- type Role
- type RolePermission
- type Session
Constants ¶
View Source
const ( LogTypeLogin = 1 LogTypePassword = 2 LogTypeAddAdminer = 3 LogTypeEditAdminer = 4 LogTypeDeleteAdminer = 5 )
View Source
const ( PermissionTypeApi uint8 = 1 PermissionTypeDef uint8 = 2 )
View Source
const ( SessionTypeAuth = 1 SessionTypeCaptcha = 2 )
View Source
const AdminerStatusLock = 2
View Source
const AdminerStatusOk = 1
Variables ¶
This section is empty.
Functions ¶
func AdminerStatusNames ¶
func HasAdminer ¶
func LogTypeNames ¶
func PermissionTypeNames ¶
Types ¶
type Adminer ¶
type Cache ¶
type Config ¶
type Log ¶
type Permission ¶
type Permission struct { Id uint32 `gorm:"primary_key;AUTO_INCREMENT"` Name string Permission string Gid uint32 Type uint8 CreatedAt uint32 UpdatedAt uint32 }
func (*Permission) TableName ¶
func (m *Permission) TableName() string
type PermissionGroup ¶
type PermissionGroup struct { Id uint32 `gorm:"primary_key;AUTO_INCREMENT"` Pid uint32 Name string Ord uint32 CreatedAt uint32 UpdatedAt uint32 }
func (*PermissionGroup) TableName ¶
func (m *PermissionGroup) TableName() string
type Role ¶
Click to show internal directories.
Click to hide internal directories.