コード例 #1
0
ファイル: ReasonController.cs プロジェクト: fathurxzz/aleqx
 public ActionResult Edit(Reason model)
 {
     var reason = _context.Reason.First(r => r.Id == model.Id);
     reason.Title = model.Title;
     reason.Text = HttpUtility.HtmlDecode(model.Text);
     _context.SaveChanges();
     return RedirectToAction("Index", "Home", new {area = ""});
 }
コード例 #2
0
ファイル: Site.Designer.cs プロジェクト: fathurxzz/aleqx
 /// <summary>
 /// Deprecated Method for adding a new object to the Reason EntitySet. Consider using the .Add method of the associated ObjectSet&lt;T&gt; property instead.
 /// </summary>
 public void AddToReason(Reason reason)
 {
     base.AddObject("Reason", reason);
 }
コード例 #3
0
ファイル: Site.Designer.cs プロジェクト: fathurxzz/aleqx
 /// <summary>
 /// Create a new Reason object.
 /// </summary>
 /// <param name="id">Initial value of the Id property.</param>
 /// <param name="title">Initial value of the Title property.</param>
 /// <param name="text">Initial value of the Text property.</param>
 public static Reason CreateReason(global::System.Int32 id, global::System.String title, global::System.String text)
 {
     Reason reason = new Reason();
     reason.Id = id;
     reason.Title = title;
     reason.Text = text;
     return reason;
 }