コード例 #1
0
 public JsonResult EditChangelog([FromBody] ChangelogEditRequest changelog)
 {
     using (var context = new DatabaseController(Context, Configuration))
     {
         context.EditChangelog(changelog);
     }
     return(Json(new object()));
 }
コード例 #2
0
 public JsonResult EditChangelog([FromBody] ChangelogEditRequest changelog)
 {
     using (var context = new ChangelogContext(Context, Config))
     {
         context.EditChangelog(changelog);
     }
     return(Json(new object()));
 }
コード例 #3
0
        internal void EditChangelog(ChangelogEditRequest changelog)
        {
            var current = Context.Changelogs.FirstOrDefault(x => x.Id == changelog.Id);

            current.LogDetails = changelog.Content;
            Context.Attach(current);
            Context.Update(current);
            Context.SaveChanges();
        }