public Entities.Orders ParseOrders(BusinessLogic.Orders o) { return(new Entities.Orders() { OrderDate = DateTime.Now, LocationId = o.Location.LocID, CustId = o.Cust.CustID, CustOrder = ParseCustOrder(o.CustOrder), Total = CalculateTotal(o.CustOrder) }); }
public void MakeOrder(BusinessLogic.Orders order) { DataLayer.Orders orders = new DataLayer.Orders { Orderid = order.Orderid, Clientname = order.Clientname, Price = order.Price }; Database.Orders.Create(orders); Database.Save(); }