Пример #1
0
 public static BusinessLogic.Models.Customer MapCustomerWithoutOrders(Entities.Customers customer)
 {
     return(new BusinessLogic.Models.Customer
     {
         ID = customer.CustomerId,
         FirstName = customer.FirstName,
         LastName = customer.LastName,
         Phone = customer.Phone,
     });
 }
Пример #2
0
 public static BusinessLogic.Models.Customer MapCustomer(Entities.Customers customer)
 {
     return(new BusinessLogic.Models.Customer
     {
         ID = customer.CustomerId,
         FirstName = customer.FirstName,
         LastName = customer.LastName,
         Phone = customer.Phone,
         OrderHistory = customer.Orders.Select(MapOrder).ToList()
     });
 }