forked from sanchezvem/pyrofetes-backend
Put roles into endpoints
This commit is contained in:
@@ -16,7 +16,7 @@ public class GetTotalQuantityEndpoint(
|
||||
public override void Configure()
|
||||
{
|
||||
Get("/wareHouseProducts/{@ProductId}", x => new { x.ProductId });
|
||||
AllowAnonymous();
|
||||
Roles("Admin","Employe");
|
||||
}
|
||||
|
||||
public override async Task HandleAsync(GetTotalQuantityRequest req, CancellationToken ct)
|
||||
|
||||
@@ -13,7 +13,7 @@ public class PatchWareHouseProductQuantityEndpoint(WarehouseProductsRepository w
|
||||
public override void Configure()
|
||||
{
|
||||
Patch("/wareHouseProducts/{@ProductId}/{@WareHouseId}/quantity", x => new { x.ProductId, x.WareHouseId });
|
||||
AllowAnonymous();
|
||||
Roles("Admin","Employe");
|
||||
}
|
||||
|
||||
public override async Task HandleAsync(PatchWareHouseProductQuantityDto req, CancellationToken ct)
|
||||
|
||||
Reference in New Issue
Block a user