userapi

package
v0.0.0-...-637df6b Latest Latest
Warning

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

Go to latest
Published: Oct 17, 2021 License: MIT Imports: 25 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewErrorResponse

func NewErrorResponse(err error) interface{}

func NewSuccessResponse

func NewSuccessResponse(data interface{}) interface{}

Types

type Controller

type Controller struct {
	JWTToken                     *auth.JWTToken
	Env                          *envconfig.EnvConfig
	Enforcer                     *casbin.Enforcer
	Router                       gin.IRouter
	CreateUserInport             createuser.Inport
	ShowUserByIDInport           showuserbyid.Inport
	ShowUserByEmailInport        showuserbyemail.Inport
	ShowUserByUsernameInport     showuserbyusername.Inport
	ShowAllUsersInport           showallusers.Inport
	UpdateUserInport             updateuser.Inport
	DeleteUserInport             deleteuser.Inport
	ActivationUserInport         activationuser.Inport
	ResetActivationUserInport    resetactivationuser.Inport
	LoginUserInport              loginuser.Inport
	ShowAllUserPostsInport       showalluserposts.Inport
	UpdatePasswordInport         updatepassword.Inport
	ForgotPasswordInport         forgotpassword.Inport
	UploadUserPhotoProfileInport uploaduserphotoprofile.Inport
}

func (*Controller) CreateUserHandler

func (r *Controller) CreateUserHandler(inputPort createuser.Inport) gin.HandlerFunc

createuserHandler ...

func (*Controller) RegisterRouter

func (r *Controller) RegisterRouter()

RegisterRouter registering all the router

type Response

type Response struct {
	Success      bool        `json:"success"`
	ErrorCode    string      `json:"errorCode"`
	ErrorMessage string      `json:"errorMessage"`
	Data         interface{} `json:"data"`
}

Jump to

Keyboard shortcuts

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