public IHttpActionResult UpdatePost(ActorViewModel model) { var response = new SimpleResponse(); response = iActorBusiness.Update(model); return(Json(response)); }
public IActionResult Put([FromBody] ActorVO item) { if (item == null) { return(BadRequest()); } var updatedItem = _business.Update(item); if (updatedItem == null) { return(NoContent()); } return(new OkObjectResult(updatedItem)); }
public IActionResult UpdatePost(ActorViewModel model) { var response = iActorBusiness.Update(model); if (response.ResponseCode > 0) { return(RedirectToAction("Index")); } else { ModelState.AddModelError(string.Empty, response.ResponseMessage); return(View("Edit", model)); } }
public SimpleResponse Update(ActorDto dto) { var response = new SimpleResponse(); try { var model = SimpleMapper.Map <ActorDto, ActorViewModel>(dto); response = iActorBusiness.Update(model); } catch (Exception ex) { response.ResponseCode = BusinessResponseValues.InternalError; response.ResponseMessage = "Güncelleme iþleminde hata oluþtu."; SimpleFileLogger.Instance.Error(ex); } return(response); }
public SimpleResponse Update(ActorViewModel model) { var response = iActorBusiness.Update(model); return(response); }