Documentation ¶
Index ¶
- func ReadInput(rBody io.ReadCloser, input interface{}) error
- func WriteCustomHTTPError(w http.ResponseWriter, statusCode int, CustomErrMessage string)
- func WriteHTTPError(w http.ResponseWriter, statusCode int)
- func WriteOKResponse(w http.ResponseWriter, m interface{})
- type UserHandlersImpl
- func (userHandlersImpl UserHandlersImpl) ApplyLeave(w http.ResponseWriter, req *http.Request)
- func (userHandlersImpl UserHandlersImpl) GetLeaves(w http.ResponseWriter, req *http.Request)
- func (userHandlersImpl UserHandlersImpl) GetLeavesByStatus(w http.ResponseWriter, req *http.Request)
- func (userHandlersImpl UserHandlersImpl) Login(w http.ResponseWriter, req *http.Request)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ReadInput ¶
func ReadInput(rBody io.ReadCloser, input interface{}) error
ReadInput from the body
func WriteCustomHTTPError ¶
func WriteCustomHTTPError(w http.ResponseWriter, statusCode int, CustomErrMessage string)
WriteCustomHTTPError **
func WriteHTTPError ¶
func WriteHTTPError(w http.ResponseWriter, statusCode int)
WriteHTTPError return HTTP Error Message
func WriteOKResponse ¶
func WriteOKResponse(w http.ResponseWriter, m interface{})
WriteOKResponse as a standard JSON response with StatusOK
Types ¶
type UserHandlersImpl ¶
type UserHandlersImpl struct {
// contains filtered or unexported fields
}
UserHandlersImpl for handler Functions
func NewUserHandlerImpl ¶
func NewUserHandlerImpl(userService service.UsersService) *UserHandlersImpl
NewUserHandlerImpl inits dependancies for graphQL and Handlers
func (UserHandlersImpl) ApplyLeave ¶
func (userHandlersImpl UserHandlersImpl) ApplyLeave(w http.ResponseWriter, req *http.Request)
ApplyLeave handler Function
func (UserHandlersImpl) GetLeaves ¶
func (userHandlersImpl UserHandlersImpl) GetLeaves(w http.ResponseWriter, req *http.Request)
GetLeaves handler Function
func (UserHandlersImpl) GetLeavesByStatus ¶
func (userHandlersImpl UserHandlersImpl) GetLeavesByStatus(w http.ResponseWriter, req *http.Request)
GetLeavesByStatus handler Function
func (UserHandlersImpl) Login ¶
func (userHandlersImpl UserHandlersImpl) Login(w http.ResponseWriter, req *http.Request)
Login Handler
Click to show internal directories.
Click to hide internal directories.