models

package
v0.0.0-...-9b02830 Latest Latest
Warning

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

Go to latest
Published: Nov 12, 2019 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GeneratePassword

func GeneratePassword(password string) ([]byte, error)

GeneratePassword encrypts password

Types

type User

type User struct {
	Id       bson.ObjectId `bson:"_id" json:"Id"`
	Username string
	Password string `json:",omitempty"`
	Email    string
	IsAdmin  bool
}

func GetInternalAPIUser

func GetInternalAPIUser() User

GetInternalAPIUser Returns an internal user with admin permissions

Jump to

Keyboard shortcuts

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