예제 #1
0
 public void Update(AnecdoteUpdateViewModel model)
 {
     repository.Update(new Anecdote {
         Id = model.Id, Title = model.Title, Content = model.Content, Owner = model.Owner, Status = model.Status
     });
     Save();
 }
예제 #2
0
 public HttpResponseMessage Update([FromBody] AnecdoteUpdateViewModel model)
 {
     service.Update(model);
     return(new HttpResponseMessage(HttpStatusCode.OK));
 }