update
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
package routes
|
||||
|
||||
import (
|
||||
"enaklo-pos-be/internal/handlers/http"
|
||||
"enaklo-pos-be/internal/handlers/http/customerauth"
|
||||
"enaklo-pos-be/internal/handlers/http/discovery"
|
||||
"enaklo-pos-be/internal/middlewares"
|
||||
@@ -14,11 +15,12 @@ func RegisterCustomerRoutes(app *app.Server, serviceManager *services.ServiceMan
|
||||
repoManager *repository.RepoManagerImpl) {
|
||||
approute := app.Group("/api/v1/customer")
|
||||
|
||||
authMiddleware := middlewares.AuthorizationMiddleware(repoManager.Crypto)
|
||||
authMiddleware := middlewares.CustomerAuthorizationMiddleware(repoManager.Crypto)
|
||||
|
||||
serverRoutes := []HTTPHandlerRoutes{
|
||||
discovery.NewHandler(serviceManager.DiscoverService),
|
||||
customerauth.NewAuthHandler(serviceManager.AuthSvc, serviceManager.UserSvc, serviceManager.CustomerV2Svc),
|
||||
customerauth.NewAuthHandler(serviceManager.AuthV2Svc),
|
||||
http.NewMenuHandler(serviceManager.ProductV2Svc, serviceManager.InProgressSvc),
|
||||
}
|
||||
|
||||
for _, handler := range serverRoutes {
|
||||
|
||||
Reference in New Issue
Block a user