Inheritance: System.Data.Objects.DataClasses.EntityObject
Exemplo n.º 1
0
 /// <summary>
 /// 用于向 Order_Details EntitySet 添加新对象的方法,已弃用。请考虑改用关联的 ObjectSet&lt;T&gt; 属性的 .Add 方法。
 /// </summary>
 public void AddToOrder_Details(Order_Detail order_Detail)
 {
     base.AddObject("Order_Details", order_Detail);
 }
Exemplo n.º 2
0
 /// <summary>
 /// 创建新的 Order_Detail 对象。
 /// </summary>
 /// <param name="orderID">OrderID 属性的初始值。</param>
 /// <param name="productID">ProductID 属性的初始值。</param>
 /// <param name="unitPrice">UnitPrice 属性的初始值。</param>
 /// <param name="quantity">Quantity 属性的初始值。</param>
 /// <param name="discount">Discount 属性的初始值。</param>
 public static Order_Detail CreateOrder_Detail(global::System.Int32 orderID, global::System.Int32 productID, global::System.Decimal unitPrice, global::System.Int16 quantity, global::System.Single discount)
 {
     Order_Detail order_Detail = new Order_Detail();
     order_Detail.OrderID = orderID;
     order_Detail.ProductID = productID;
     order_Detail.UnitPrice = unitPrice;
     order_Detail.Quantity = quantity;
     order_Detail.Discount = discount;
     return order_Detail;
 }