userModel

package
v0.0.0-...-83e3b5c Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 21, 2021 License: BSD-3-Clause Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Create

func Create(newUser *userSchema.UserSchema) (user *userSchema.UserSchema, err error)

func DelUser

func DelUser(username string) (err error)

func FindUsers

func FindUsers(query string) (users []*userSchema.UserSchema, err error)

func GenerateUsername

func GenerateUsername(first_name, last_name string) string

func Get

func Get(username string) (user *userSchema.UserSchema, err error)

func GetAll

func GetAll() (users []*userSchema.UserSchema, err error)

func NewAuthToken

func NewAuthToken(username string) (token string, err error)

func Seed

func Seed() (err error)

func Update

func Update(username string, updateUser *userSchema.UserSchema) (user *userSchema.UserSchema, err error)

func ValidateCreate

func ValidateCreate(newUser *userSchema.UserSchema) (errors []string)

func ValidateUpdate

func ValidateUpdate(newUser *userSchema.UserSchema) (errors []string)

func VerifyAuthToken

func VerifyAuthToken(token string) (user *userSchema.UserSchema, err error)

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL