Documentation ¶
Index ¶
- type User
- func (u *User) ChangeUserPassword(id string, passwd string) error
- func (u *User) ChangeUserSettings(id string, settings map[string]string) error
- func (u *User) CreateUser(user models.User) (models.User, error)
- func (u *User) GetAllUsers() ([]models.User, error)
- func (u *User) GetUserById(id string) (models.User, error)
- func (u *User) GetUserByUsername(username string) (models.User, error)
- func (u *User) UpdateUserData(id string, fullname string, email string, isadmin bool, iswriter bool) error
- type UserScheme
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type User ¶
type User struct {
// contains filtered or unexported fields
}
func (*User) ChangeUserSettings ¶
func (*User) GetUserById ¶
GetUserById(id string) (models.User, error)
func (*User) GetUserByUsername ¶
GetUser(username string) (models.User, error)
type UserScheme ¶
type UserScheme struct { UserName string `bson:"user_name"` FullName string `bson:"full_name"` Password string `bson:"passwd"` Email string `bson:"email"` IsAdmin bool `bson:"is_admin"` IsWriter bool `bson:"is_writer"` Id primitive.ObjectID `bson:"_id"` LastLogin time.Time `bson:"last_login"` CreationDate time.Time `bson:"creation_date"` Settings map[string]string `bson:"settings"` }
Click to show internal directories.
Click to hide internal directories.