public ActionResult Create(OnlineCommentsModel model) { if (ModelState.IsValid) { OnlineComments info = new OnlineComments(); info.Id = Guid.NewGuid(); info.Title = model.Title; info.Content = model.Content; ////背景介绍 //info.BackgroundIntroduction = model.BackgroundIntroduction; ////草案全文 //info.DraftFullText = model.DraftFullText; ////公众意见与建议 //info.Opinion = model.Opinion; ////公众意见采纳情况反馈 //info.Feedback = model.Feedback; //是否结束 info.IsEnd = model.IsEnd; info.StartTime = model.StartTime; info.EndTime = model.EndTime; service.Add(info); return(Json(new AjaxResult() { Result = Result.Success })); } return(View(PluginHelper.GetViewPath(this.GetType(), "Create"), model)); }
public void Update(OnlineComments info) { var query = repository.Table; repository.Update(info); }
public void Delete(OnlineComments info) { repository.Delete(info); }
public void Add(OnlineComments info) { var query = repository.Table; repository.Insert(info); }