Skip to content

Commit

Permalink
Routing fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
Rethakgetse-Manaka committed Jun 9, 2024
1 parent d164da6 commit bc5c303
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions occupi-backend/pkg/router/router.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,10 @@ func OccupiRouter(router *gin.Engine, db *mongo.Client) {
api := router.Group("/api")
{
api.GET("/resource-auth", middleware.ProtectedRoute, func(ctx *gin.Context) { handlers.FetchResourceAuth(ctx, appsession) }) // authenticated
api.GET("/book-room", middleware.UnProtectedRoute, func(ctx *gin.Context) { handlers.BookRoom(ctx, appsession) })
api.GET("/check-in", middleware.UnProtectedRoute, func(ctx *gin.Context) { handlers.CheckIn(ctx, appsession) })
api.GET("cancel-booking", middleware.UnProtectedRoute, func(ctx *gin.Context) { handlers.CancelBooking(ctx, appsession) })
api.GET(("view-bookings"), middleware.UnProtectedRoute, func(ctx *gin.Context) { handlers.ViewBookings(ctx, appsession) })
api.GET("/book-room", middleware.ProtectedRoute, func(ctx *gin.Context) { handlers.BookRoom(ctx, appsession) })
api.GET("/check-in", middleware.ProtectedRoute, func(ctx *gin.Context) { handlers.CheckIn(ctx, appsession) })
api.GET("cancel-booking", middleware.ProtectedRoute, func(ctx *gin.Context) { handlers.CancelBooking(ctx, appsession) })
api.GET(("view-bookings"), middleware.ProtectedRoute, func(ctx *gin.Context) { handlers.ViewBookings(ctx, appsession) })
}
auth := router.Group("/auth")
{
Expand Down

0 comments on commit bc5c303

Please sign in to comment.