Documentation ¶
Index ¶
- type AuthDao
- func (p *AuthDao) AddRole(db *gorm.DB, user uint, name string, resource_type string, resource_id uint, ...)
- func (p *AuthDao) Auth(db *gorm.DB, email, password string) *User
- func (p *AuthDao) Can(db *gorm.DB, user uint, name string, resource_type string, resource_id uint) bool
- func (p *AuthDao) Confirm(db *gorm.DB, user uint)
- func (p *AuthDao) CreateByEmail(db *gorm.DB, email, name, password string) *User
- func (p *AuthDao) DelRole(db *gorm.DB, user uint, name string, resource_type string, resource_id uint)
- func (p *AuthDao) GetByEmail(db *gorm.DB, email string) *User
- func (p *AuthDao) Log(db *gorm.DB, user uint, message string, flag string)
- func (p *AuthDao) ResetUid(db *gorm.DB, user uint)
- type Contact
- type DateZone
- type Engine
- func (p Engine) Info() (string, string)
- func (p *Engine) Locales(c *web.Context) *web.HttpError
- func (p *Engine) Migrate() error
- func (p *Engine) Mount()
- func (p *Engine) Rss(c *web.Context) *web.HttpError
- func (p *Engine) Seed() error
- func (p *Engine) SiteInfo(c *web.Context) *web.HttpError
- func (p *Engine) Sitemap(c *web.Context) *web.HttpError
- type Locale
- type LocaleDao
- type Log
- type Model
- type Permission
- type Role
- type Setting
- type SettingDao
- type User
- type VModel
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AuthDao ¶
func (*AuthDao) CreateByEmail ¶
type Engine ¶
type LocaleDao ¶
type LocaleDao struct {
Logger *logging.Logger `inject:""`
}
-----------------------------------------------------------------------------
type Permission ¶
type Role ¶
type Role struct { ID uint Name string `sql:"size:255;index;not null"` ResourceType string `sql:"size:255;index;not null"` ResourceID uint `sql:"index;not null"` Permissions []Permission }
type SettingDao ¶
-----------------------------------------------------------------------------
type User ¶
type User struct { Model Uid string `sql:"not null;type:UUID;default:gen_random_uuid()"` Name string `sql:"not null;size:64;index"` Email string `sql:"size:128;index"` Token string `sql:"size:255;index;not null"` Provider string `sql:"size:16;not null;default:'email';index"` Password []byte `sql:"size:64"` Confirmed *time.Time Locked *time.Time ContactID uint `sql:"not null"` Contact Contact Logs []Log Permissions []Permission }
Click to show internal directories.
Click to hide internal directories.