cup/routes.go

31 lines
1.1 KiB
Go
Raw Normal View History

2024-09-12 19:15:38 -04:00
// Copyright 2023 Harran Ali <harran.m@gmail.com>. All rights reserved.
// Copyright (c) 2024 Zeni Kim <zenik@smarteching.com>
// Use of this source code is governed by MIT-style
// license that can be found in the LICENSE file.
package main
import (
"git.smarteching.com/goffee/core"
2024-09-15 20:01:52 -04:00
"git.smarteching.com/goffee/cup/controllers"
"git.smarteching.com/goffee/cup/middlewares"
2024-09-12 19:15:38 -04:00
)
2024-09-15 20:01:52 -04:00
// Register the app controllers
2024-09-12 19:15:38 -04:00
func registerRoutes() {
2024-09-15 20:01:52 -04:00
controller := core.ResolveRouter()
2024-09-12 19:15:38 -04:00
//#############################
//# App Routes #####
//#############################
// Define your routes here...
2024-09-15 20:01:52 -04:00
controller.Get("/", controllers.WelcomeHome)
2024-09-12 19:15:38 -04:00
// Uncomment the lines below to enable authentication
2024-09-15 20:01:52 -04:00
// controller.Post("/signup", controllers.Signup)
// controller.Post("/signin", controllers.Signin)
// controller.Post("/signout", controllers.Signout)
// controller.Post("/reset-password", controllers.ResetPasswordRequest)
// controller.Post("/reset-password/code/:code", controllers.SetNewPassword)
controller.Get("/dashboard", controllers.WelcomeToDashboard, middlewares.AuthCheck)
2024-09-12 19:15:38 -04:00
}