Example #1
0
func CreateUserRoutes(router *router, s gorm.DB) *router {
	c := controllers.NewAuthenticationController(s)

	router.Post("/create-user", CommonHandlers.ThenFunc(c.CreateUser))
	return router
}
Example #2
0
func ForgotPasswordChangeRoutes(router *router, s gorm.DB) *router {
	c := controllers.NewAuthenticationController(s)

	router.Post("/change-forgot-pass", CommonHandlers.ThenFunc(c.ForgotPasswordChange))
	return router
}
Example #3
0
func ChangePasswordRoutes(router *router, s gorm.DB) *router {
	c := controllers.NewAuthenticationController(s)

	router.Post("/change-pass", CommonHandlers.ThenFunc(c.ChangePassword))
	return router
}
Example #4
0
func IsValidTokenRoutes(router *router, s gorm.DB) *router {
	c := controllers.NewAuthenticationController(s)

	router.Post("/is-valid", CommonHandlers.ThenFunc(c.IsValidForgotPasswordToken))
	return router
}
Example #5
0
func LoginRoutes(router *router, s gorm.DB) *router {
	c := controllers.NewAuthenticationController(s)

	router.Post("/login", CommonHandlers.ThenFunc(c.Login))
	return router
}