modifs mineures
This commit is contained in:
@@ -4,7 +4,7 @@ using PyroFetes.DTO.Contact.Response;
|
||||
|
||||
namespace PyroFetes.Endpoints.Contact;
|
||||
|
||||
public class GetAllContactxuest(PyroFetesDbContext pyroFetesDbContext) : EndpointWithoutRequest<List<GetContactDto>>
|
||||
public class GetAllContactEndpoint(PyroFetesDbContext pyroFetesDbContext) : EndpointWithoutRequest<List<GetContactDto>>
|
||||
{
|
||||
public override void Configure()
|
||||
{
|
||||
|
||||
+3
-1
@@ -5,7 +5,7 @@ using PyroFetes.DTO.Contact.Response;
|
||||
|
||||
namespace PyroFetes.Endpoints.Contact;
|
||||
|
||||
public class UpdateContactRequest(PyroFetesDbContext pyroFetesDbContext) : Endpoint <UpdateContactDto, GetContactDto>
|
||||
public class UpdateContactEndpoint(PyroFetesDbContext pyroFetesDbContext) : Endpoint <UpdateContactDto, GetContactDto>
|
||||
{
|
||||
public override void Configure()
|
||||
{
|
||||
@@ -29,6 +29,7 @@ public class UpdateContactRequest(PyroFetesDbContext pyroFetesDbContext) : Endpo
|
||||
databaseContact.PhoneNumber = req.PhoneNumber;
|
||||
databaseContact.Email = req.Email;
|
||||
databaseContact.Address = req.Address;
|
||||
databaseContact.City = req.City;
|
||||
databaseContact.Role = req.Role;
|
||||
}
|
||||
await pyroFetesDbContext.SaveChangesAsync(ct);
|
||||
@@ -41,6 +42,7 @@ public class UpdateContactRequest(PyroFetesDbContext pyroFetesDbContext) : Endpo
|
||||
PhoneNumber = req.PhoneNumber,
|
||||
Email = req.Email,
|
||||
Address = req.Address,
|
||||
City = req.City,
|
||||
Role = req.Role,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user