Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateDefaultOVConfig ¶
func CreateDefaultUsers ¶
func CreateDefaultUsers()
Types ¶
type OVConfig ¶
type OVConfig struct { Id int Profile string `orm:"size(64);unique" valid:"Required;"` config.Config }
OVConfig holds values for OpenVPN config file
type Settings ¶
type Settings struct { Id int64 Profile string `orm:"size(64);unique" form:"Profile" valid:"Required;"` MIAddress string `orm:"size(64);unique" form:"MIAddress" valid:"Required;"` MINetwork string `orm:"size(64);unique" form:"MINetwork" valid:"Required;"` OVConfigPath string `orm:"size(64);unique" form:"OVConfigPath" valid:"Required;"` ServerAddress string `orm:"size(64);unique" form:"ServerAddress" valid:"Required;"` ServerPort int `orm:"" form:"ServerPort" valid:"Required;"` Created time.Time `orm:"auto_now_add;type(datetime)"` Updated time.Time `orm:"auto_now;type(datetime)"` }
func CreateDefaultSettings ¶
type User ¶
type User struct { Id int64 Login string `orm:"size(64);unique" form:"Login" valid:"Required;"` Name string `orm:"size(64);unique" form:"Name" valid:"Required;"` Email string `orm:"size(64);unique" form:"Email" valid:"Required;Email"` Password string `orm:"size(32)" form:"Password" valid:"Required;MinSize(6)"` Repassword string `orm:"-" form:"Repassword" valid:"Required"` Lastlogintime time.Time `orm:"type(datetime);null" form:"-"` Created time.Time `orm:"auto_now_add;type(datetime)"` Updated time.Time `orm:"auto_now;type(datetime)"` }
func (*User) Valid ¶
func (u *User) Valid(v *validation.Validation)
Click to show internal directories.
Click to hide internal directories.