示例#1
0
 /// <summary>
 /// Deprecated Method for adding a new object to the Products EntitySet. Consider using the .Add method of the associated ObjectSet&lt;T&gt; property instead.
 /// </summary>
 public void AddToProducts(Product product)
 {
     base.AddObject("Products", product);
 }
示例#2
0
 /// <summary>
 /// Create a new Product object.
 /// </summary>
 /// <param name="productID">Initial value of the ProductID property.</param>
 /// <param name="categoryID">Initial value of the CategoryID property.</param>
 /// <param name="productName">Initial value of the ProductName property.</param>
 /// <param name="description">Initial value of the Description property.</param>
 /// <param name="content">Initial value of the Content property.</param>
 /// <param name="images">Initial value of the Images property.</param>
 /// <param name="percentDiscount">Initial value of the PercentDiscount property.</param>
 /// <param name="price">Initial value of the Price property.</param>
 /// <param name="typeProduct">Initial value of the TypeProduct property.</param>
 /// <param name="isHot">Initial value of the IsHot property.</param>
 /// <param name="createDate">Initial value of the CreateDate property.</param>
 /// <param name="packageID">Initial value of the PackageID property.</param>
 /// <param name="status">Initial value of the Status property.</param>
 public static Product CreateProduct(global::System.Int32 productID, global::System.Int32 categoryID, global::System.String productName, global::System.String description, global::System.String content, global::System.String images, global::System.Int32 percentDiscount, global::System.Int32 price, global::System.Int32 typeProduct, global::System.Boolean isHot, global::System.DateTime createDate, global::System.Int32 packageID, global::System.Int32 status)
 {
     Product product = new Product();
     product.ProductID = productID;
     product.CategoryID = categoryID;
     product.ProductName = productName;
     product.Description = description;
     product.Content = content;
     product.Images = images;
     product.PercentDiscount = percentDiscount;
     product.Price = price;
     product.TypeProduct = typeProduct;
     product.IsHot = isHot;
     product.CreateDate = createDate;
     product.PackageID = packageID;
     product.Status = status;
     return product;
 }