/// <summary> /// 更新程序设计按钮 /// </summary> /// <param name="programButton">程序设计按钮实体</param> public int Update(Model.ProgramButton programButton) { using (var db = new DataContext()) { db.Update(programButton); return(db.SaveChanges()); } }
/// <summary> /// 更新程序设计按钮 /// </summary> /// <param name="programButton">程序设计按钮实体</param> public int Update(Model.ProgramButton programButton) { return(programButtonData.Update(programButton)); }
/// <summary> /// 添加一个程序设计按钮 /// </summary> /// <param name="programButton">程序设计按钮实体</param> /// <returns></returns> public int Add(Model.ProgramButton programButton) { return(programButtonData.Add(programButton)); }