user

package
v0.0.0-...-3f885a5 Latest Latest
Warning

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

Go to latest
Published: May 9, 2019 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SignIn

func SignIn(c *gin.Context)

func SignUp

func SignUp(c *gin.Context)

func Userinfo

func Userinfo(c *gin.Context)

Types

type SignInPostData

type SignInPostData struct {
	UserName string `json:"username"`
	PassWord string `json:"password"`
}

type SignUpPostData

type SignUpPostData struct {
	Email    string `json:"email"`
	UserName string `json:"username"`
	PassWord string `json:"password"`
}

type UserRes

type UserRes struct {
	ID        bson.ObjectId `json:"id" bson:"_id"`
	Name      string        `json:"name"`
	Email     string        `json:"email"`
	Signature string        `json:"signature"`
	Avatar    string        `json:"avatar"`
	UserName  string        `json:"username"`
	CreatedAt int64         `json:"createdAt"`
	UpdatedAt int64         `json:"updatedAt"`
}

func SaveUser

func SaveUser(data SignUpPostData) (UserRes, error)

Jump to

Keyboard shortcuts

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