entities

package
v0.0.0-...-a470d62 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2021 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LoginCredentials

type LoginCredentials struct {
	Email    string `json:"email"`
	Password string `json:"password"`
}

type User

type User struct {
	ID       primitive.ObjectID `json:"id,omitempty" bson:"_id,omitempty"`
	Name     string             `json:"name" validate:"required"`
	LastName string             `json:"lastName" validate:"required"`
	Email    string             `json:"email" validate:"required,email"`
	Password string             `json:"password" validate:"required,password"`
}

func (*User) DoPasswordMatch

func (u *User) DoPasswordMatch(currPassword string) bool

func (*User) HashPassword

func (u *User) HashPassword() error

func (*User) Validate

func (u *User) Validate() error

type UserData

type UserData struct {
	// contains filtered or unexported fields
}

func NewUserData

func NewUserData(logger *log.Logger) *UserData

Jump to

Keyboard shortcuts

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