feat: add static file serving and refactor route registration
This commit is contained in:
@@ -17,12 +17,13 @@ import (
|
||||
// Routes implements the HttpRoute contract and provides route registration
|
||||
// for all controllers in the super module.
|
||||
//
|
||||
// @provider contracts.HttpRoute atom.GroupRoutes
|
||||
// @provider contracts.HttpRoute atom.GroupRoutes
|
||||
type Routes struct {
|
||||
log *log.Entry `inject:"false"`
|
||||
// Controller instances
|
||||
authController *authController
|
||||
tenant *tenant
|
||||
authController *authController
|
||||
staticController *staticController
|
||||
tenant *tenant
|
||||
}
|
||||
|
||||
// Prepare initializes the routes provider with logging configuration.
|
||||
@@ -59,5 +60,7 @@ func (r *Routes) Register(router fiber.Router) {
|
||||
Body[dto.TenantExpireUpdateForm]("form"),
|
||||
))
|
||||
|
||||
router.Get("/super/*", Func(r.staticController.static))
|
||||
|
||||
r.log.Info("Successfully registered all routes")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user