Documentation
¶
Index ¶
Examples ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( HasEngine bool DbCfg struct { Type, Host, Name, User, Pwd, Path, SslMode string } EnableSQLite3 bool UseSQLite3 bool )
Functions ¶
func DumpDatabase ¶
DumpDatabase dumps all data from database to file system.
func IsUserExist ¶
IsUserExist checks if given user name exist, the user name should be noncased unique.
func LoadModelsConfig ¶
func LoadModelsConfig()
Example ¶
fmt.Println("hello, and") fmt.Println("goodbye")
Output: hello, and goodbye
Types ¶
type Statistic ¶
type Statistic struct { Counter struct { User int64 } }
func GetStatistic ¶
func GetStatistic() (stats Statistic)
type User ¶
type User struct { Id int64 LowerName string `xorm:"unique not null"` Name string `xorm:"unique not null"` FullName string Email string `xorm:"unique not null"` Password string `xorm:"not null"` LoginName string Avatar string `xorm:"varchar(2048) not null"` Location string Website string IsActive bool IsAdmin bool Created time.Time `xorm:"created"` Updated time.Time `xorm:"updated"` }
User represents the object of individual and member of organization.
func GetUserByName ¶
GetUserByName returns the user object by given name if exists.
Click to show internal directories.
Click to hide internal directories.