types

package
v0.0.0-...-be022e4 Latest Latest
Warning

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

Go to latest
Published: Dec 27, 2020 License: GPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type User

type User struct {
	ID        primitive.ObjectID `bson:"_id,omitempty" json:"id,omitempty" binding:"-"`
	FirstName string             `json:"firstName" bson:"firstName" form:"firstName" binding:"required"`
	LastName  string             `json:"lastName" bson:"lastName" form:"lastName" binding:"required"`
	Email     string             `json:"email" bson:"email" houseflow:"email" form:"email" binding:"required,email"`
	Password  string             `json:"password" bson:"password" form:"password" binding:"required,min=8,max=20"`
}

User struct, used to either creating user, or this one in DB

func (*User) CreateAccessToken

func (u *User) CreateAccessToken() (*string, error)

CreateAccessToken creates JWT access token for user

Jump to

Keyboard shortcuts

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