/// <summary> /// Deprecated Method for adding a new object to the OrderDetails EntitySet. /// </summary> public void AddToOrderDetails(OrderDetails orderDetails) { base.AddObject("OrderDetails", orderDetails); }
/// <summary> /// Create a new OrderDetails object. /// </summary> /// <param name="orderID">Initial value of OrderID.</param> /// <param name="productID">Initial value of ProductID.</param> /// <param name="unitPrice">Initial value of UnitPrice.</param> /// <param name="quantity">Initial value of Quantity.</param> /// <param name="discount">Initial value of Discount.</param> public static OrderDetails CreateOrderDetails(int orderID, int productID, decimal unitPrice, int quantity, decimal discount) { OrderDetails orderDetails = new OrderDetails(); orderDetails.OrderID = orderID; orderDetails.ProductID = productID; orderDetails.UnitPrice = unitPrice; orderDetails.Quantity = quantity; orderDetails.Discount = discount; return orderDetails; }