/// <summary> /// Create a new ProductionPriority object. /// </summary> /// <param name="id">Initial value of the ID property.</param> /// <param name="code">Initial value of the Code property.</param> /// <param name="name">Initial value of the Name property.</param> public static ProductionPriority CreateProductionPriority(global::System.Decimal id, global::System.String code, global::System.String name) { ProductionPriority productionPriority = new ProductionPriority(); productionPriority.ID = id; productionPriority.Code = code; productionPriority.Name = name; return productionPriority; }
/// <summary> /// Deprecated Method for adding a new object to the ProductionPriorities EntitySet. Consider using the .Add method of the associated ObjectSet<T> property instead. /// </summary> public void AddToProductionPriorities(ProductionPriority productionPriority) { base.AddObject("ProductionPriorities", productionPriority); }
public ActionResult _InsertPriority() { ProductionPriority newPriority = new ProductionPriority(); if (TryUpdateModel(newPriority)) { PrdnDBContext.ProductionPriorities.AddObject(newPriority); PrdnDBContext.SaveChanges(); } return View(PriorityGridList()); }