users

package
v0.0.0-...-78f5e88 Latest Latest
Warning

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

Go to latest
Published: Mar 28, 2021 License: AGPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddUser

func AddUser(login string, password string) int

func CheckDatabase

func CheckDatabase()

func GetUserIdByLogin

func GetUserIdByLogin(login string) (userId int, found bool)

func IsCredentialsValid

func IsCredentialsValid(login string, password string) bool

Types

type User

type User struct {
	Id             int
	Login          string
	PasswordHash   string
	Salt           string
	CreatedDateUtc time.Time
}

func GetAll

func GetAll() []User

func GetUserById

func GetUserById(userId int) (user User, found bool)

func GetUserByLogin

func GetUserByLogin(login string) (user User, found bool)

Jump to

Keyboard shortcuts

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