Пример #1
0
 public Customer Map(CustomerContract contract) =>
 new Customer
 {
     Id          = contract.Id,
     City        = contract.City,
     CompanyName = contract.CompanyName,
     Phone       = contract.Phone,
     PostalCode  = contract.PostalCode
 };
 public void AddCustomer(CustomerContract customer)
 {
     _repository.Add(_mapper.Map(customer));
 }