From af79db8726d12aa3eecabc1365260238801774b4 Mon Sep 17 00:00:00 2001 From: "Hafizh A. Y" Date: Sun, 11 Jan 2026 08:41:45 +0700 Subject: [PATCH] fix(BE): permission in payment route --- internal/modules/finance/payments/route.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/internal/modules/finance/payments/route.go b/internal/modules/finance/payments/route.go index b00de964..c2931f0a 100644 --- a/internal/modules/finance/payments/route.go +++ b/internal/modules/finance/payments/route.go @@ -13,9 +13,9 @@ func PaymentRoutes(v1 fiber.Router, u user.UserService, s payment.PaymentService ctrl := controller.NewPaymentController(s) route := v1.Group("/payments") - // route.Use(m.Auth(u)) + route.Use(m.Auth(u)) - route.Post("/", ctrl.CreateOne) + route.Post("/", m.RequirePermissions(m.P_Finances_Payments_CreateOne), ctrl.CreateOne) route.Get("/:id", m.RequirePermissions(m.P_Finances_Payments_GetOne), ctrl.GetOne) route.Patch("/:id", m.RequirePermissions(m.P_Finances_Payments_UpdateOne), ctrl.UpdateOne) }