added AllowAnonymous();

This commit is contained in:
2025-11-17 21:25:07 +01:00
parent 6dba61f742
commit 0511bb5075
23 changed files with 26 additions and 3 deletions

View File

@@ -10,6 +10,7 @@ public class CreateSupplierEndpoint(PyroFetesDbContext database) : Endpoint<Crea
public override void Configure()
{
Post("/api/suppliers");
AllowAnonymous();
}
public override async Task HandleAsync(CreateSupplierDto req, CancellationToken ct)

View File

@@ -14,6 +14,7 @@ public class DeleteSupplierEndpoint(PyroFetesDbContext database) : Endpoint<Dele
public override void Configure()
{
Delete("/api/suppliers/{@Id}", x => new {x.Id});
AllowAnonymous();
}
public override async Task HandleAsync(DeleteSupplierRequest req, CancellationToken ct)

View File

@@ -9,6 +9,7 @@ public class GetAllSuppliersEndpoint(PyroFetesDbContext database) : EndpointWith
public override void Configure()
{
Get("/api/suppliers");
AllowAnonymous();
}
public override async Task HandleAsync(CancellationToken ct)

View File

@@ -15,6 +15,7 @@ public class GetSupplierEndpoint(PyroFetesDbContext database) : Endpoint<GetSupp
public override void Configure()
{
Get("/api/suppliers/{@Id}", x => new {x.Id});
AllowAnonymous();
}
public override async Task HandleAsync(GetSupplierRequest req, CancellationToken ct)

View File

@@ -10,7 +10,8 @@ public class PatchSupplierDeleveryDelayEndpoint(PyroFetesDbContext database) : E
{
public override void Configure()
{
Get("/api/supplier/{@Id}/DeleveryDalay", x => new {x.Id});
Patch("/api/supplier/{@Id}/DeleveryDalay", x => new {x.Id});
AllowAnonymous();
}
public override async Task HandleAsync(PatchSupplierDeliveryDelayDto req, CancellationToken ct)

View File

@@ -11,6 +11,7 @@ public class UpdateSupplierEndpoint(PyroFetesDbContext database) : Endpoint<Upda
public override void Configure()
{
Put("/api/suppliers/{@Id}", x => new {x.Id});
AllowAnonymous();
}
public override async Task HandleAsync(UpdateSupplierDto req, CancellationToken ct)