Commit 17a7a1c9 authored by hasan khaddour's avatar hasan khaddour

Remove Duplicated value objects

parent 0c387bd4
......@@ -6,5 +6,8 @@ using System.Threading.Tasks;
namespace PSManagement.Contracts.Customers.Requests
{
public record AddContactInfoRequest(int CustomerId, String ContactType, String ContactValue);
public record AddContactInfoRequest(
int CustomerId,
String ContactType,
String ContactValue);
}
using System;
using PSManagement.Domain.Customers.ValueObjects;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
......@@ -8,14 +9,8 @@ namespace PSManagement.Contracts.Customers.Requests
{
public record CreateCustomerRequest(
String CustomerName,
AddressRecord Address ,
Address Address ,
String Email
);
public record AddressRecord(
String StreetName ,
int StreetNumber,
int ZipCode ,
String City
);
}
using System;
using PSManagement.Domain.Customers.ValueObjects;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
......@@ -9,6 +10,6 @@ namespace PSManagement.Contracts.Customers.Requests
public record UpdateCustomerRequest(
int CustomerId,
String CustomerName,
AddressRecord Address,
Address Address,
String Email);
}
using PSManagement.Contracts.Customers.Requests;
using PSManagement.Domain.Customers.ValueObjects;
using System;
using System.Collections.Generic;
......@@ -13,7 +14,7 @@ namespace PSManagement.Contracts.Customers.Responses
public int Id { get; set; }
public String CustomerName { get; set; }
public String Email { get; set; }
public AddressRecord Address { get; set; }
public Address Address { get; set; }
public IEnumerable<ContactInfoRecord> ContactInfo { get; set; }
}
}
......@@ -4,4 +4,8 @@
<TargetFramework>net5.0</TargetFramework>
</PropertyGroup>
<ItemGroup>
<ProjectReference Include="..\PSManagement.Domain\PSManagement.Domain.csproj" />
</ItemGroup>
</Project>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment